1 ################################################################################
5 ################################################################################
7 MONGODB_VERSION_BASE
= 3.3.4
8 MONGODB_VERSION
= r
$(MONGODB_VERSION_BASE
)
9 MONGODB_SITE
= $(call github
,mongodb
,mongo
,$(MONGODB_VERSION
))
11 MONGODB_LICENSE
= AGPLv3
, Apache-2.0
12 MONGODB_LICENSE_FILES
= GNU-AGPL-3.0.txt APACHE-2.0.txt
14 MONGODB_DEPENDENCIES
= host-scons
16 MONGODB_SCONS_TARGETS
= mongod mongos
18 MONGODB_SCONS_ENV
= CC
="$(TARGET_CC)" CXX
="$(TARGET_CXX)" \
21 MONGODB_SCONS_OPTS
= --disable-warnings-as-errors
23 # need to pass mongo version when not building from git repo
24 MONGODB_SCONS_OPTS
+= MONGO_VERSION
=$(MONGODB_VERSION_BASE
)-
26 # WiredTiger database storage engine only supported on 64 bits
27 ifeq ($(BR2_ARCH_IS_64
),y
)
28 MONGODB_SCONS_OPTS
+= --wiredtiger
=on
30 MONGODB_SCONS_OPTS
+= --wiredtiger
=off
33 # JavaScript scripting engine and tcmalloc supported only on
34 # x86/x86-64 systems. Mongo target is a shell interface that
35 # depends on the javascript engine, so it will also only be
36 # built on x86/x86-64 systems.
37 ifeq ($(BR2_i386
)$(BR2_x86_64
),y
)
38 MONGODB_SCONS_OPTS
+= --js-engine
=mozjs
--allocator
=tcmalloc
39 MONGODB_SCONS_TARGETS
+= mongo
41 MONGODB_SCONS_OPTS
+= --js-engine
=none
--allocator
=system
44 ifeq ($(BR2_PACKAGE_OPENSSL
),y
)
45 MONGODB_DEPENDENCIES
+= openssl
46 MONGODB_SCONS_OPTS
+= --ssl
=SSL
49 define MONGODB_BUILD_CMDS
52 $(MONGODB_SCONS_ENV
) \
53 $(MONGODB_SCONS_OPTS
) \
54 $(MONGODB_SCONS_TARGETS
))
57 define MONGODB_INSTALL_TARGET_CMDS
60 $(MONGODB_SCONS_ENV
) \
61 $(MONGODB_SCONS_OPTS
) \
62 --prefix=$(TARGET_DIR
)/usr \
66 $(eval
$(generic-package
))