openssl: support building the binary without MMU
authorBenoît Thébaudeau <benoit@wsystem.com>
Fri, 19 Jun 2015 10:54:33 +0000 (12:54 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tue, 30 Jun 2015 14:44:12 +0000 (16:44 +0200)
The commit 720893b62510438237b9923d744dd079ddb4f67d "openssl: disable
apps for NOMMU" prevented the openssl binary from being built without
MMU in order to fix a build failure without fork(). However, openssl is
designed to support the lack of fork() with -DHAVE_FORK=0, so allow the
openssl binary to be enabled without MMU thanks to this option.

Signed-off-by: Benoît Thébaudeau <benoit@wsystem.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/openssl/Config.in
package/openssl/openssl.mk

index 07859ca0c74357c8dac3b5f1def4eb3dde2cdda2..d147c071e87fb05f99cbb70188c625a180832f2a 100644 (file)
@@ -13,15 +13,12 @@ if BR2_PACKAGE_OPENSSL
 
 config BR2_PACKAGE_OPENSSL_BIN
        bool "openssl binary"
-       # uses fork()
-       depends on BR2_USE_MMU
        depends on !BR2_STATIC_LIBS
        help
          Install the openssl binary to the target file system. This is a
          command line tool for doing various crypthographic stuff.
 
 comment "openssl binary needs a toolchain w/ dynamic library"
-       depends on BR2_USE_MMU
        depends on BR2_STATIC_LIBS
 
 config BR2_PACKAGE_OPENSSL_ENGINES
index fd8904d28b3aba64c4f5d06e067d3bee973c5e6b..34a98307548f733a5623676c18236e210b86e583 100644 (file)
@@ -22,6 +22,10 @@ endef
 OPENSSL_PRE_CONFIGURE_HOOKS += OPENSSL_DISABLE_APPS
 endif
 
+ifeq ($(BR2_USE_MMU),)
+OPENSSL_CFLAGS += -DHAVE_FORK=0
+endif
+
 ifeq ($(BR2_PACKAGE_CRYPTODEV_LINUX),y)
 OPENSSL_CFLAGS += -DHAVE_CRYPTODEV -DUSE_CRYPTODEV_DIGESTS
 OPENSSL_DEPENDENCIES += cryptodev-linux