mongoose: add optional openssl support
authorPeter Korsgaard <jacmet@sunsite.dk>
Thu, 2 May 2013 20:59:23 +0000 (22:59 +0200)
committerPeter Korsgaard <jacmet@sunsite.dk>
Thu, 2 May 2013 20:59:23 +0000 (22:59 +0200)
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
package/mongoose/mongoose.mk

index 4f7df17f36173440f0bc8d3cd3d4959729ff4263..ac03bb62904201e26558f3c3b1804d58016549b0 100644 (file)
@@ -10,7 +10,15 @@ MONGOOSE_SITE = https://mongoose.googlecode.com/files
 MONGOOSE_LICENSE = MIT
 MONGOOSE_LICENSE_FILES = COPYING
 
-MONGOOSE_CFLAGS = $(TARGET_CFLAGS) $(TARGET_LDFLAGS) -DNO_SSL
+MONGOOSE_CFLAGS = $(TARGET_CFLAGS) $(TARGET_LDFLAGS)
+
+ifeq ($(BR2_PACKAGE_OPENSSL),y)
+MONGOOSE_DEPENDENCIES += openssl
+# directly linked
+MONGOOSE_CFLAGS += -DNO_SSL_DL -lssl -lcrypto -lz
+else
+MONGOOSE_CFLAGS += -DNO_SSL
+endif
 
 define MONGOOSE_BUILD_CMDS
        $(MAKE) CC="$(TARGET_CC)" LD="$(TARGET_LD)" -C $(@D) \