Edit

IABSD.fr/ports/databases/mongodb/Makefile

Branch :

  • Show log

    Commit

  • Author : sthen
    Date : 2017-04-06 22:11:23
    Hash : 41c2b048
    Message : update to mongodb-3.2.12, from Andrew Aldridge (plus remove REVISION)

  • databases/mongodb/Makefile
  • # $OpenBSD: Makefile,v 1.24 2017/04/06 22:11:23 sthen Exp $
    
    PORTROACH =	limitw:1,even
    USE_WXNEEDED =	Yes
    
    # The default storage engine (WiredTiger) only works on amd64.
    ONLY_FOR_ARCHS = amd64
    DPB_PROPERTIES = parallel
    
    COMMENT =	scalable, high-performance document-oriented database
    
    DISTNAME =	mongodb-src-r3.2.12
    PKGNAME =	${DISTNAME:S/src-r//}
    CATEGORIES =	databases
    
    HOMEPAGE =	https://www.mongodb.com/
    
    # mongodb itself: AGPLv3
    # client/utils:   Apache 2.0
    PERMIT_PACKAGE_CDROM =	Yes
    
    WANTLIB += boost_chrono-mt boost_filesystem-mt boost_program_options-mt
    WANTLIB += boost_regex-mt boost_system-mt boost_thread-mt c crypto
    WANTLIB += execinfo kvm m pcap pcre pcrecpp pthread ssl yaml-cpp
    WANTLIB += z
    
    MASTER_SITES =	https://fastdl.mongodb.org/src/
    
    MODULES =	gcc4 \
    		devel/scons \
    		lang/python
    
    # XXX should come from scons module, but broken when gcc module also used:
    NO_CCACHE =	Yes
    
    MODGCC4_ARCHS =	*
    MODGCC4_LANGS =	c c++
    MODPY_VERSION =	${MODPY_DEFAULT_VERSION_2}
    MODSCONS_ENV =	CC="${CC}" \
    		CXX="${CXX}" \
    		CCFLAGS="${CFLAGS} -DBOOST_NO_USER_CONFIG" \
    		CXXFLAGS="${CXXFLAGS}" \
    		LINKFLAGS="${LDFLAGS}" \
    		CPPPATH="${LOCALBASE}/include" \
    		LIBPATH="${LOCALBASE}/lib"
    MODSCONS_FLAGS += --prefix="${PREFIX}" \
    		  --opt=on \
    		  --ssl=SSL \
    		  --allocator=system \
    		  --use-system-boost \
    		  --use-system-pcre \
    		  --use-system-yaml \
    		  --use-system-zlib \
    		  -j${MAKE_JOBS}
    
    ALL_TARGET =	core tools
    LIB_DEPENDS =	devel/libexecinfo \
    		devel/boost \
    		devel/pcre \
    		devel/yaml-cpp
    TEST_DEPENDS =	textproc/py-yaml \
    		databases/py-mongo
    # icu4c support is not actually compiled in, but scons picks up the
    # headers and patching this away is intrusive
    BUILD_DEPENDS =	textproc/icu4c
    
    do-install:
    .for bin in mongo mongod mongos mongosniff mongobridge mongoperf
    	${INSTALL_PROGRAM} ${WRKSRC}/${bin} ${PREFIX}/bin/
    	if [ -f ${WRKSRC}/debian/${bin}.1 ]; then \
    	  ${INSTALL_MAN} ${WRKSRC}/debian/${bin}.1 ${PREFIX}/man/man1; \
    	fi
    .endfor
    	${INSTALL_DATA_DIR} ${PREFIX}/share/examples/mongodb
    	${INSTALL_DATA} ${FILESDIR}/mongodb.conf \
    	    ${PREFIX}/share/examples/mongodb
    
    do-test:
    	@${SETENV} ${MAKE_ENV} ${MODSCONS_BIN} -C ${WRKSRC} \
    	    ${MODSCONS_ENV} ${MODSCONS_FLAGS} unittests
    	cd ${WRKSRC} && ${MODPY_BIN} buildscripts/resmoke.py --suites=unittests
    
    .include <bsd.port.mk>