erlang: Remove BR2_TOOLCHAIN_HAS_THREADS dependency
authorEzequiel García <ezequiel@vanguardiasur.com.ar>
Tue, 20 Oct 2015 13:54:46 +0000 (10:54 -0300)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Wed, 21 Oct 2015 20:12:05 +0000 (22:12 +0200)
Erlang can be built without threads support, by passing an
appropriate config option.

This commit drops the config dependency on BR2_TOOLCHAIN_HAS_THREADS
and instead passes --disable-threads if the toolchain doesn't support
threads.

While here, change the wording of the config comment to "dynamic
library" to be consistent with similar comments elsewhere.

Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/erlang/Config.in
package/erlang/erlang.mk

index 625b7c1b829fa951c50e6b842ce8051710e8a4c2..0ec01bb749b4f5f7e846baf52d3243e4d46019b5 100644 (file)
@@ -1,12 +1,11 @@
-comment "erlang needs a toolchain w/ threads, shared library"
+comment "erlang needs a toolchain w/ dynamic library"
        depends on BR2_USE_MMU # fork()
        depends on BR2_PACKAGE_LIBATOMIC_ARCH_SUPPORTS
-       depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS
+       depends on BR2_STATIC_LIBS
 
 config BR2_PACKAGE_ERLANG
        bool "erlang"
        depends on BR2_USE_MMU # fork()
-       depends on BR2_TOOLCHAIN_HAS_THREADS
        depends on !BR2_STATIC_LIBS
        depends on BR2_PACKAGE_LIBATOMIC_ARCH_SUPPORTS
        select BR2_PACKAGE_LIBATOMIC_OPS
index 499f62c1539b497a254ddd893fb3d1f2daee17d6..848d1ddc44c560179db6e58b3a50e4f165173b54 100644 (file)
@@ -40,6 +40,10 @@ HOST_ERLANG_CONF_OPTS = --without-javac --with-ssl=$(HOST_DIR)/usr
 
 HOST_ERLANG_CONF_OPTS += --without-termcap
 
+ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),)
+ERLANG_CONF_OPTS += --disable-threads
+endif
+
 ifeq ($(BR2_PACKAGE_NCURSES),y)
 ERLANG_CONF_OPTS += --with-termcap
 ERLANG_DEPENDENCIES += ncurses