Skip to content

Commit

Permalink
Support OTP 23 and later
Browse files Browse the repository at this point in the history
  • Loading branch information
kipcole9 committed Apr 9, 2021
1 parent 5165d18 commit 51b20f4
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 4 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
# Changelog for Ex_Cldr_Collation v0.4.0

This is the changelog for Cldr_collation v0.4.0 released on April 9th, 2021. For older changelogs please consult the release tag on [GitHub](https://github.com/elixir-cldr/cldr_units/tags)

### Bug Fixes

* Fix compilation issues on OTP 23 and later. On these releases, `liberl_interface.a` doesn't exist and isn't required. Thanks to @zookzook for the report.

# Changelog for Ex_Cldr_Collation v0.3.0

This is the changelog for Cldr_collation v0.3.0 released on March 3rd, 2020. For older changelogs please consult the release tag on [GitHub](https://github.com/elixir-cldr/cldr_units/tags)
Expand Down
11 changes: 10 additions & 1 deletion c_src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,16 @@ else ifeq ($(UNAME_SYS), Linux)
endif

CFLAGS += -fPIC -I$(ERTS_INCLUDE_DIR) -I$(ERL_INTERFACE_INCLUDE_DIR)
LDLIBS += -L$(ERL_INTERFACE_LIB_DIR) -lerl_interface -lei

# On OTP 23 and later, liberl_interface.a doesn't exist and
# isn't requried

ifneq ("$(wildcard $(ERL_INTERFACE_LIB_DIR)/liberl_interface.a)","")
LDLIBS += -L$(ERL_INTERFACE_LIB_DIR) -lerl_interface -lei
else
LDLIBS += -L$(ERL_INTERFACE_LIB_DIR) -lei
endif

LDFLAGS += -shared

ifeq ($(UNAME_SYS), Darwin)
Expand Down
6 changes: 3 additions & 3 deletions mix.exs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
defmodule CldrCollation.MixProject do
use Mix.Project

@version "0.3.0"
@version "0.4.0"

def project do
[
Expand Down Expand Up @@ -38,7 +38,7 @@ defmodule CldrCollation.MixProject do
defp deps do
[
{:elixir_make, "~> 0.4", runtime: false},
{:ex_doc, "~> 0.19", only: [:dev, :release], runtime: false, optional: true},
{:ex_doc, "~> 0.19", runtime: false, optional: true},
{:ex_cldr, "~> 2.0"},
{:jason, "~> 1.0"}
]
Expand Down Expand Up @@ -80,7 +80,7 @@ defmodule CldrCollation.MixProject do
"LICENSE.md",
"CHANGELOG.md"
],
skip_undefined_reference_warnings_on: ["changelog"]
skip_undefined_reference_warnings_on: ["changelog", "CHANGELOG.md"]
]
end

Expand Down

0 comments on commit 51b20f4

Please sign in to comment.