pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/databases/mongodb Import mongodb-3.0.2 as databases/mo...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/1d79edbef2db
branches:  trunk
changeset: 651095:1d79edbef2db
user:      ryoon <ryoon%pkgsrc.org@localhost>
date:      Sat May 02 08:10:33 2015 +0000

description:
Import mongodb-3.0.2 as databases/mongodb from pkgsrc-wip/mongodb.

Packged by jafour1 and updated by some users.


Mongo (from "humongous") is a high-performance, open source, schema-free,
document-oriented database. It features: document data model with dynamic
schemas; full, flexible index support and rich queries; auto-Sharding for
horizontal scalability; built-in replication for high availability; text
search; advanced security; aggregation Framework and MapReduce; large media
storage with GridFS.

diffstat:

 databases/mongodb/CL                                                                           |   11 +
 databases/mongodb/DESCR                                                                        |    6 +
 databases/mongodb/Makefile                                                                     |  127 ++++++++
 databases/mongodb/PLIST                                                                        |   22 +
 databases/mongodb/distinfo                                                                     |   16 +
 databases/mongodb/files/mongodb.sh                                                             |   37 ++
 databases/mongodb/files/smf/manifest.xml                                                       |   40 ++
 databases/mongodb/files/smf/mongodb.sh                                                         |   33 ++
 databases/mongodb/options.mk                                                                   |   11 +
 databases/mongodb/patches/patch-SConstruct                                                     |   84 +++++
 databases/mongodb/patches/patch-debian_mongod.conf                                             |   23 +
 databases/mongodb/patches/patch-src_mongo_base_initializer.h                                   |   13 +
 databases/mongodb/patches/patch-src_mongo_db_repl_isself.c                                     |   24 +
 databases/mongodb/patches/patch-src_mongo_platform_random.cpp                                  |   14 +
 databases/mongodb/patches/patch-src_mongo_shell_linenoise__utf8.h                              |   26 +
 databases/mongodb/patches/patch-src_third__party_s2_base_port.h                                |   27 +
 databases/mongodb/patches/patch-src_third__party_v8-3.25_SConscript                            |   35 ++
 databases/mongodb/patches/patch-src_third__party_v8-3.25_src_platform-posix.cc                 |   29 +
 databases/mongodb/patches/patch-src_third__party_wiredtiger_SConscript                         |   24 +
 databases/mongodb/patches/patch-src_third__party_wiredtiger_build__netbsd_wiredtiger__config.h |  158 ++++++++++
 20 files changed, 760 insertions(+), 0 deletions(-)

diffs (truncated from 840 to 300 lines):

diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/CL
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/CL      Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,11 @@
+Import databases/mongodb 3.0.2 from pkgsrc-wip/mongodb
+
+Packged by jafour1 and updated by some users.
+
+
+Mongo (from "humongous") is a high-performance, open source, schema-free,
+document-oriented database. It features: document data model with dynamic
+schemas; full, flexible index support and rich queries; auto-Sharding for
+horizontal scalability; built-in replication for high availability; text
+search; advanced security; aggregation Framework and MapReduce; large media
+storage with GridFS.
diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/DESCR   Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,6 @@
+Mongo (from "humongous") is a high-performance, open source, schema-free,
+document-oriented database. It features: document data model with dynamic
+schemas; full, flexible index support and rich queries; auto-Sharding for
+horizontal scalability; built-in replication for high availability; text
+search; advanced security; aggregation Framework and MapReduce; large media
+storage with GridFS.
diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/Makefile        Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,127 @@
+# $NetBSD: Makefile,v 1.1 2015/05/02 08:10:33 ryoon Exp $
+
+DISTNAME=      mongodb-src-r3.0.2
+PKGNAME=       ${DISTNAME:S/src-r//:S/-rc/rc/}
+CATEGORIES=    databases
+MASTER_SITES=  http://fastdl.mongodb.org/src/
+
+MAINTAINER=    bartosz.kuzma%gmail.com@localhost
+HOMEPAGE=      http://mongodb.org/
+COMMENT=       NoSQL distributed document-oriented database
+LICENSE=       gnu-agpl-v3 # Client and tools licensed under apache-2.0
+
+NO_CONFIGURE=  yes
+USE_LANGUAGES= c c++
+
+BUILD_DEPENDS+=        scons-[0-9]*:../../devel/scons
+
+SCONS_BIN=     ${PREFIX}/bin/scons
+SCONS_ARGS=    ${_MAKE_JOBS}
+SCONS_ARGS=    --c++11=on
+SCONS_ARGS+=   --cc=${WRAPPER_BINDIR}/${CC:Q}
+SCONS_ARGS+=   --cxx=${WRAPPER_BINDIR}/${CXX:Q}
+SCONS_ARGS+=   --use-system-boost=USE-SYSTEM-BOOST
+SCONS_ARGS+=   --use-system-pcre=USE-SYSTEM-PCRE
+SCONS_ARGS+=   --use-system-snappy=USE-SYSTEM-SNAPPY
+SCONS_ARGS+=   --use-system-tcmalloc=USE-SYSTEM-TCMALLOC
+SCONS_ARGS+=   --js-engine=v8-3.25
+# Avoid Argument list too long from mongod linking
+SCONS_ARGS+=   --variant-dir=pkgsrc
+
+.include "../../mk/bsd.prefs.mk"
+
+.if ${MACHINE_ARCH} == "x86_64"
+SCONS_ARGS+=   --64
+.else
+SCONS_ARGS+=   --32
+.endif
+
+CPPFLAGS+=     -fno-jump-tables
+
+.include "options.mk"
+
+SMF_METHODS+=          mongodb
+
+BUILD_DEFS+=           VARBASE
+BUILD_DEFS+=           MONGODB_USER MONGODB_GROUP MONGODB_DBPATH
+BUILD_DEFS+=           MONGODB_LOGPATH
+
+MONGODB_USER?=         mongodb
+MONGODB_GROUP?=                mongodb
+MONGODB_DBPATH?=       ${VARBASE}/mongodb
+MONGODB_LOGPATH?=      ${VARBASE}/log/mongodb
+
+PKG_USERS_VARS+=       MONGODB_USER
+PKG_GROUPS_VARS+=      MONGODB_GROUP
+
+PKG_GROUPS=            ${MONGODB_GROUP}
+PKG_USERS=             ${MONGODB_USER}:${MONGODB_GROUP}
+
+PKG_GECOS.${MONGODB_USER}=     MongoDB database administrator
+PKG_HOME.${MONGODB_USER}=      ${MONGODB_DBPATH}
+PKG_SHELL.${MONGODB_USER}=     ${SH}
+
+OWN_DIRS_PERMS+=       ${MONGODB_DBPATH} ${MONGODB_USER} ${MONGODB_GROUP} 0755
+OWN_DIRS_PERMS+=       ${MONGODB_DBPATH}/journal ${MONGODB_USER} ${MONGODB_GROUP} 0755
+OWN_DIRS_PERMS+=       ${MONGODB_LOGPATH} ${MONGODB_USER} ${MONGODB_GROUP} 0755
+
+FILES_SUBST+=          MONGODB_USER=${MONGODB_USER}
+FILES_SUBST+=          MONGODB_GROUP=${MONGODB_GROUP}
+FILES_SUBST+=          MONGODB_DBPATH=${MONGODB_DBPATH}
+FILES_SUBST+=          MONGODB_LOGPATH=${MONGODB_LOGPATH}
+
+# XXX No better idea how to pass CXXFLAGS and LDFLAGS to scons
+SUBST_CLASSES+=                scons
+SUBST_STAGE.scons=     pre-build
+SUBST_FILES.scons=     SConstruct
+SUBST_VARS.scons=      PREFIX CXXFLAGS LDFLAGS
+
+SUBST_CLASSES+=                path
+SUBST_STAGE.path=      pre-build
+SUBST_FILES.path=      src/mongo/db/flushtest.cpp debian/mongod.conf
+SUBST_FILES.path+=     debian/mongod.1 debian/mongo.1 src/mongo/shell/dbshell.cpp
+SUBST_SED.path=                -e 's|/data/db|${MONGODB_DBPATH}|g'
+SUBST_SED.path+=       -e 's|/etc|${PKG_SYSCONFDIR}|'
+SUBST_VARS.path=       MONGODB_DBPATH MONGODB_LOGPATH
+
+MONGODB_MAN_FILES=     bsondump.1 mongo.1 mongod.1 mongodump.1 mongoexport.1   \
+                       mongofiles.1 mongoimport.1 mongooplog.1 mongoperf.1     \
+                       mongorestore.1 mongos.1 mongosniff.1 mongostat.1 mongotop.1
+
+RCD_SCRIPTS=           mongodb
+
+INSTALLATION_DIRS+=    share/doc/mongodb share/examples/mongodb ${PKGMANDIR}/man1
+
+CONF_FILES+=           share/examples/mongodb/mongod.conf \
+                       ${PKG_SYSCONFDIR}/mongod.conf
+
+post-extract:
+       chmod -R g-w ${WRKSRC}
+
+do-build:
+       cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${SCONS_BIN} ${SCONS_ARGS} core
+
+do-install:
+       cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${SCONS_BIN} ${SCONS_ARGS} \
+               --prefix=${DESTDIR}${PREFIX} install
+
+do-test:
+       cd ${WRKSRC} && ./test
+
+post-install:
+       ${INSTALL_DATA} ${WRKSRC}/README ${DESTDIR}${PREFIX}/share/doc/mongodb
+.for file in ${MONGODB_MAN_FILES}
+       ${INSTALL_MAN} ${WRKSRC}/debian/${file} \
+               ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
+.endfor
+       ${INSTALL_DATA} ${WRKSRC}/debian/mongod.conf \
+               ${DESTDIR}${PREFIX}/share/examples/mongodb
+
+.include "../../devel/boost-headers/buildlink3.mk"
+.include "../../devel/boost-libs/buildlink3.mk"
+.include "../../devel/boost-python/buildlink3.mk"
+.include "../../devel/libexecinfo/buildlink3.mk"
+.include "../../devel/pcre/buildlink3.mk"
+.include "../../devel/snappy/buildlink3.mk"
+.include "../../net/libpcap/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/PLIST
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/PLIST   Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,22 @@
+@comment $NetBSD: PLIST,v 1.1 2015/05/02 08:10:33 ryoon Exp $
+bin/mongo
+bin/mongod
+bin/mongoperf
+bin/mongos
+bin/mongosniff
+man/man1/bsondump.1
+man/man1/mongo.1
+man/man1/mongod.1
+man/man1/mongodump.1
+man/man1/mongoexport.1
+man/man1/mongofiles.1
+man/man1/mongoimport.1
+man/man1/mongooplog.1
+man/man1/mongoperf.1
+man/man1/mongorestore.1
+man/man1/mongos.1
+man/man1/mongosniff.1
+man/man1/mongostat.1
+man/man1/mongotop.1
+share/doc/mongodb/README
+share/examples/mongodb/mongod.conf
diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/distinfo        Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,16 @@
+$NetBSD: distinfo,v 1.1 2015/05/02 08:10:33 ryoon Exp $
+
+SHA1 (mongodb-src-r3.0.2.tar.gz) = c24c4deb619e199d5c3688370b39ea6e4a4df204
+RMD160 (mongodb-src-r3.0.2.tar.gz) = 12571664adca8bcec7fe8daa6ee2a8a120261aea
+Size (mongodb-src-r3.0.2.tar.gz) = 26594777 bytes
+SHA1 (patch-SConstruct) = 656921b86b686c0dd2005036629d0149d6f713e7
+SHA1 (patch-debian_mongod.conf) = 35f3d7e7da4f573458bef0fe742c1790adec8200
+SHA1 (patch-src_mongo_base_initializer.h) = add32c5940c922a98122d0e6883eb3ad52dc25c5
+SHA1 (patch-src_mongo_db_repl_isself.c) = 93001bf0616c0fd64ac5e7ea03113885671540b0
+SHA1 (patch-src_mongo_platform_random.cpp) = ab275e90347a9d2e767f031df4e56a204647ddfe
+SHA1 (patch-src_mongo_shell_linenoise__utf8.h) = d505c22aeeee09b482bf3d3a6bd0cdc45c9ec0bc
+SHA1 (patch-src_third__party_s2_base_port.h) = 8e715efbfcacaba51d957c21aa32ccfd3cc4f736
+SHA1 (patch-src_third__party_v8-3.25_SConscript) = a8da59130c36b2be3b89498ba0b23b1c7c9ab9e6
+SHA1 (patch-src_third__party_v8-3.25_src_platform-posix.cc) = 2fa27016a9af828d1c01815739770918a2d53d16
+SHA1 (patch-src_third__party_wiredtiger_SConscript) = 576ae923cd77c5d21f44f82fc6bde7c3b5ffa250
+SHA1 (patch-src_third__party_wiredtiger_build__netbsd_wiredtiger__config.h) = e41064c0ff7268efc795782312ff413295cbcba7
diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/files/mongodb.sh
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/files/mongodb.sh        Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,37 @@
+#!@RCD_SCRIPTS_SHELL@
+#
+# $NetBSD: mongodb.sh,v 1.1 2015/05/02 08:10:33 ryoon Exp $
+#
+# PROVIDE: mongodb
+# REQUIRE: DAEMON LOGIN mountall
+# KEYWORD: shutdown
+#
+# You will need to set some variables in /etc/rc.conf to start MongoDB:
+#
+# mongodb=YES
+#
+# The following variables are optional:
+#
+#     mongodb_user="@MONGODB_USER@"    # user to run mongod as
+#     mongodb_group="@MONGODB_GROUP@"  # group to run mongod as
+#     mongodb_dbpath="@MONGODB_DBPATH@"        # path to MongoDB database directory
+#
+
+if [ -f /etc/rc.subr ]; then
+       . /etc/rc.subr
+fi
+
+name="mongodb"
+rcvar=${name}
+command="@PREFIX@/bin/mongod"
+: ${mongodb_user:=@MONGODB_USER@}
+: ${mongodb_group:=@MONGODB_GROUP@}
+: ${mongodb_dbpath:=@MONGODB_DBPATH@}
+pidfile="${mongodb_dbpath}/mongod.pid"
+logfile="${mongodb_dbpath}/mongod.log"
+required_dirs="${mongodb_dbpath}"
+
+command_args="--fork --logpath ${logfile} --logappend --pidfilepath ${pidfile} --dbpath ${mongodb_dbpath} --smallfiles"
+
+load_rc_config ${name}
+run_rc_command "$1"
diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/files/smf/manifest.xml
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/files/smf/manifest.xml  Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,40 @@
+<?xml version='1.0'?>
+<!DOCTYPE service_bundle SYSTEM '/usr/share/lib/xml/dtd/service_bundle.dtd.1'>
+<service_bundle type='manifest' name='export'>
+  <service name='@SMF_PREFIX@/@SMF_NAME@' type='service' version='0'>
+    <create_default_instance enabled='false'/>
+    <single_instance/>
+    <dependency name='fs' grouping='require_all' restart_on='none' type='service'>
+      <service_fmri value='svc:/system/filesystem/local'/>
+    </dependency>
+    <dependency name='net' grouping='require_all' restart_on='none' type='service'>
+      <service_fmri value='svc:/network/loopback'/>
+    </dependency>
+    <dependency name='config' grouping='require_all' restart_on='none' type='path'>
+      <service_fmri value='file://@PKG_SYSCONFDIR@/mongod.conf'/>
+    </dependency>
+    <method_context working_directory='@MONGODB_DBPATH@'>
+      <method_credential group='@MONGODB_USER@' user='@MONGODB_GROUP@'/>
+        <method_environment>
+          <envvar name='PATH' value='@PREFIX@/bin:@PREFIX@/gnu/bin:@PREFIX@/sbin:/usr/bin:/usr/sbin'/>
+        </method_environment>
+    </method_context>
+    <exec_method name='start' type='method' exec='@PREFIX@/@SMF_METHOD_FILE.mongodb@ start' timeout_seconds='18446744073709551615'/>
+    <exec_method name='stop' type='method' exec='@PREFIX@/@SMF_METHOD_FILE.mongodb@ stop' timeout_seconds='18446744073709551615'/>
+    <exec_method name='restart' type='method' exec='@PREFIX@/@SMF_METHOD_FILE.mongodb@ restart' timeout_seconds='18446744073709551615'/>
+      <property_group name='replication' type='application'>
+       <propval name='name' type='astring' value=''/>
+       <propval name='key' type='astring' value=''/>
+       <propval name='members' type='astring' value=''/>
+      </property_group>
+      <template>
+        <common_name>
+          <loctext xml:lang='C'>MongoDB Database</loctext>
+        </common_name>
+        <documentation>
+          <doc_link name='wiki.joyent.com' uri='http://wiki.joyent.com/display/jpc2/Joyent+MongoDB+SmartMachine'/>
+        </documentation>
+      </template>
+  </service>
+</service_bundle>
+
diff -r a5e5b6f92be8 -r 1d79edbef2db databases/mongodb/files/smf/mongodb.sh
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/mongodb/files/smf/mongodb.sh    Sat May 02 08:10:33 2015 +0000
@@ -0,0 +1,33 @@
+#!/bin/bash
+#
+# SMF method for svc:/pkgsrc/mongodb:default
+
+. /lib/svc/share/smf_include.sh
+
+# mongodb doesn't really work with anything else but C locale
+export LANG=C
+



Home | Main Index | Thread Index | Old Index