summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexys Jacob <ultrabug@gentoo.org>2011-04-13 14:56:32 +0000
committerAlexys Jacob <ultrabug@gentoo.org>2011-04-13 14:56:32 +0000
commit6017db51c6805c01cd1ba55d0a8e6a092c339374 (patch)
treed02ad37db57df69cbf726e9983559f7c70d3604d /dev-db/mongodb
parentDepend on dev-libs/boost, remove local copy. Bug #363187 (diff)
downloadhistorical-6017db51c6805c01cd1ba55d0a8e6a092c339374.tar.gz
historical-6017db51c6805c01cd1ba55d0a8e6a092c339374.tar.bz2
historical-6017db51c6805c01cd1ba55d0a8e6a092c339374.zip
Mongodb rework/bump. Fix bugs #329167, #334081, #337085, #337593, #337973, #338039, #340032, #356731. Many thanks to Johan Bergström for his help and testing. Drop old versions.
Package-Manager: portage-2.1.9.45/cvs/Linux x86_64
Diffstat (limited to 'dev-db/mongodb')
-rw-r--r--dev-db/mongodb/ChangeLog19
-rw-r--r--dev-db/mongodb/Manifest33
-rw-r--r--dev-db/mongodb/files/mongodb-1.2-modify-post-strip.patch11
-rw-r--r--dev-db/mongodb/files/mongodb-1.2-modify-testing.patch44
-rw-r--r--dev-db/mongodb/files/mongodb-1.4-modify-post-strip.patch12
-rw-r--r--dev-db/mongodb/files/mongodb-1.4-modify-testing.patch44
-rw-r--r--dev-db/mongodb/files/mongodb-1.6-fix-scons.patch39
-rw-r--r--dev-db/mongodb/files/mongodb-1.6.0-fix-scons.patch22
-rw-r--r--dev-db/mongodb/files/mongodb-1.8-fix-scons.patch39
-rw-r--r--dev-db/mongodb/files/mongodb.confd4
-rw-r--r--dev-db/mongodb/files/mongodb.initd48
-rw-r--r--dev-db/mongodb/files/mongos.confd13
-rw-r--r--dev-db/mongodb/files/mongos.initd43
-rw-r--r--dev-db/mongodb/mongodb-1.2.4.ebuild61
-rw-r--r--dev-db/mongodb/mongodb-1.4.4.ebuild61
-rw-r--r--dev-db/mongodb/mongodb-1.5.5.ebuild63
-rw-r--r--dev-db/mongodb/mongodb-1.6.0.ebuild78
-rw-r--r--dev-db/mongodb/mongodb-1.6.5.ebuild82
-rw-r--r--dev-db/mongodb/mongodb-1.8.1.ebuild82
19 files changed, 350 insertions, 448 deletions
diff --git a/dev-db/mongodb/ChangeLog b/dev-db/mongodb/ChangeLog
index e322b3b8283d..670a6333a763 100644
--- a/dev-db/mongodb/ChangeLog
+++ b/dev-db/mongodb/ChangeLog
@@ -1,6 +1,23 @@
# ChangeLog for dev-db/mongodb
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/ChangeLog,v 1.13 2011/03/30 17:25:19 ultrabug Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/ChangeLog,v 1.14 2011/04/13 14:56:32 ultrabug Exp $
+
+*mongodb-1.8.1 (13 Apr 2011)
+*mongodb-1.6.5 (13 Apr 2011)
+
+ 13 Apr 2011; Ultrabug <ultrabug@gentoo.org> -mongodb-1.2.4.ebuild,
+ -files/mongodb-1.2-modify-post-strip.patch,
+ -files/mongodb-1.2-modify-testing.patch, -mongodb-1.4.4.ebuild,
+ -files/mongodb-1.4-modify-post-strip.patch,
+ -files/mongodb-1.4-modify-testing.patch, -mongodb-1.5.5.ebuild,
+ -mongodb-1.6.0.ebuild, -files/mongodb-1.6.0-fix-scons.patch,
+ +mongodb-1.6.5.ebuild, +files/mongodb-1.6-fix-scons.patch,
+ +mongodb-1.8.1.ebuild, +files/mongodb-1.8-fix-scons.patch,
+ +files/mongos.confd, +files/mongos.initd, files/mongodb.confd,
+ files/mongodb.initd:
+ Mongodb rework/bump. Fix bugs #329167, #334081, #337085, #337593, #337973,
+ #338039, #340032, #356731. Many thanks to Johan Bergström for his help and
+ testing. Drop old versions.
30 Mar 2011; Ultrabug <ultrabug@gentoo.org> mongodb-1.2.4.ebuild,
mongodb-1.4.4.ebuild, mongodb-1.5.5.ebuild, mongodb-1.6.0.ebuild:
diff --git a/dev-db/mongodb/Manifest b/dev-db/mongodb/Manifest
index b84f4b5f2636..7e4e86d1946f 100644
--- a/dev-db/mongodb/Manifest
+++ b/dev-db/mongodb/Manifest
@@ -1,27 +1,22 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
-AUX mongodb-1.2-modify-post-strip.patch 456 RMD160 dae0e77c3e6e0bb867b972586a907b438b2f9de8 SHA1 5021957e1165b897e3ec74d1d8b2d4d81f66809e SHA256 85f6c2eacdacc316c7ebb5ce373da7593daf32b097435c1deb2516a600f69ca3
-AUX mongodb-1.2-modify-testing.patch 1480 RMD160 3a9f0814141d55fccf41d45d9d376fefad273322 SHA1 18fb11b60afdbc489788ff9cb315700067a99807 SHA256 40646380a5ef57a3d92a7db9b606932f681432beb3054d885e7c5778f533470d
-AUX mongodb-1.4-modify-post-strip.patch 600 RMD160 bf952ef7d985d31a769d121257ba5f62411e2548 SHA1 a11eb89aaa9e63a0ed1cca1b00dc1525ccc3fafc SHA256 cac8a7f7fc5ffad038e63e9333bffe7eba63f84774aae6c286ffa7084cb5c584
-AUX mongodb-1.4-modify-testing.patch 1740 RMD160 d088dd48d5e50c497ff0e46bd7175d53e7466e75 SHA1 7226248469498a9c3589b66fd7ef5b224a8e4a47 SHA256 e1f72cd97f69ec9241e38b4efd3380e068ee081e3e45116163cbbe6f55b89798
-AUX mongodb-1.6.0-fix-scons.patch 913 RMD160 54b30020c2d1a0313e796f132d589969d84f245d SHA1 c5473464452417be6a2bb2433b40bba336910fc1 SHA256 de26882ff9adcf46eb2227e185f7d880549333f0e87703cdf984cd1c4612ffd9
-AUX mongodb.confd 285 RMD160 cc5e3ab24a9880a19392a7416d23d1ae7a328e11 SHA1 7c4b720ea5b0afd2fa88a6adc2d8a2e356691413 SHA256 8dfedbb433e11f8ed6ec8159ed5c02f94c22f86006cda21f0b2bb59ebe50b2ad
-AUX mongodb.initd 1129 RMD160 92a89d9d71ffcdaba8f86f1a2902abddc9866147 SHA1 2c83bfe4c5728ffc8b3dc37fd8d345d09c13f6b0 SHA256 c318a8ca1fe83c59df759b2c70e0e0c22fe38cae49de6dbd1afa8399ef626e6a
-DIST mongodb-src-r1.2.4.tar.gz 3879698 RMD160 1d2e9f629cb2af620f0543138773d744817657b2 SHA1 a3d09fea3ac5bde7955520d99fe546e102ac6474 SHA256 8ebeca780d461c9a525230f4ef7321f07753cfebc21f0051be2d430cc99a605d
-DIST mongodb-src-r1.4.4.tar.gz 1188403 RMD160 34b095adde58d7a2f3bb56b59547dd3d6ac4ed8f SHA1 deb45cafd90f0700add328e0af74adc5f605197b SHA256 535b2830b74c14ea431f781a2b1bf2533cde6293235c3cdc215e13f9bdc08ebf
-DIST mongodb-src-r1.5.5.tar.gz 1426519 RMD160 e396f68c2d21fa13799dab03eaf1fe2b22bfc6fd SHA1 50ccf8f2b2855dd36d24b79929f7b877f83e0ad8 SHA256 d5f99c845dfb9c2c324decd86854162176b00b146b89d1aa49c3e6692e61aa18
-DIST mongodb-src-r1.6.0.tar.gz 1486095 RMD160 26edbeff2940fac6d2b083ce37b28aa468ed0b00 SHA1 9f3b0c90424022a8a1667d25162c67c58800edf9 SHA256 a81cb6445e003d6e73a983336855ddadf0ae4334d49f3a5ce6757d1261bd4c77
-EBUILD mongodb-1.2.4.ebuild 1479 RMD160 68c6e1b98c1a96a9652acb8c2b4cf77e893f3850 SHA1 402f825f76b5c09b5e47abb00b94aa770099d175 SHA256 7e1c2e1e1e428330aa91418095ec8bfa1c94f52cfb558d70e5973381f45066d8
-EBUILD mongodb-1.4.4.ebuild 1479 RMD160 6cc1041e7094293549383bf38b627e5b5f514548 SHA1 588b72bf01c79c44d9d9b46bf57fc677c51753bb SHA256 dc8510ca6a652c011bd08c90303119c872074742e5e264716b762da3940397a6
-EBUILD mongodb-1.5.5.ebuild 1555 RMD160 c8e20260afbe1cfe6e2dabc7a51537e894df7a8c SHA1 39a20c0bede8efdabb8ad6af2fc487bbe3557ff0 SHA256 856ba4755615e3ad99244c14ba37c9d62c881248db7f5ca96a28d49b1c6305c1
-EBUILD mongodb-1.6.0.ebuild 1918 RMD160 b31e1cdf604cc9d3c79f3902387c131da29af04f SHA1 1d4940379541804e7d5d2185ff23fc3c741e1ae9 SHA256 368b9c679e750639dfeb16cc649088791b4c05640c8a3ba604cdfd905f57f301
-MISC ChangeLog 3395 RMD160 178ca8454f99fd550e7f0bea558afe46d17e4e32 SHA1 f186f23787cde5631ea4da0cdbc145455c34b1fb SHA256 c439ac6ed906da1a34568765d039bcc7d490ccfdfffe7cb22ac0b5d4e91556d0
+AUX mongodb-1.6-fix-scons.patch 1468 RMD160 54011fed1646e1be90962a6595cbecdec1833c35 SHA1 e76feb1ba4f6973e1e382cd505d23f9c4291e9a9 SHA256 8b903e6cb95b92314a91a540b8773d5c7e85721f25ef4e176bd3eeb4673072cb
+AUX mongodb-1.8-fix-scons.patch 1649 RMD160 1e5be2fe75f25c511b1d70dd1dd7977c8f1a6db3 SHA1 1300bbc5ff4f9c4a59e89fb3e119506b3507906d SHA256 5b8db8f66adabbdd52c364a713ce38a937c4ac6282a4ac530d14930d386d582d
+AUX mongodb.confd 277 RMD160 a6c7f01ecc843c9138046a5b4deaaff839b7bcc4 SHA1 cb04bf6b4d3799846b9ab59dc587c88093d8e265 SHA256 b5b44beb64aae30f285c4764acbb8b2c7c60bd0cdcd47c6c11f285790c42b510
+AUX mongodb.initd 1019 RMD160 9b5b825228208a7656ccc03e248eb9e8fdcf7757 SHA1 51936bea587cc8186d57877ce8293933aec30252 SHA256 922e274456872cdf961299b35ddbfd27901694bcb6acd0df0a2e62f151c31d23
+AUX mongos.confd 261 RMD160 cd0164a9f54d53871a5a15ea15034479e9360d1d SHA1 193e29ae8a33dbd6490698955e6e36601a395c4b SHA256 56b63b536e2e0482972efb1505d3a661511dc9ed5872c12933a141470f1923a8
+AUX mongos.initd 1176 RMD160 4463298c196ddb8784115680fca6e6362d93d21e SHA1 94d7d526d1fda14888bbb8ba3e3b70df4354db70 SHA256 83f2f456b9a95454ad081efdcc18eb868b7ba1d348c1e7e753199467768049e0
+DIST mongodb-src-r1.6.5.tar.gz 1506561 RMD160 de98b9558544eafb809131347b6a339c46f09732 SHA1 4aed2da91377c2a5c8722c0c6873117014faf31a SHA256 5feac5302be91eea758851d28e4ad09ff4d11a28ffcb61e792ab7aeb5327a8a0
+DIST mongodb-src-r1.8.1.tar.gz 1718969 RMD160 e8739fd15c40eac9934045af4365c13f204d16fe SHA1 615cfe4ace4899e73a7083059c7178d8f5c19f03 SHA256 8b268b4f8c4d055c74add1fc995f103d893657c4291964d370899ebefd0bc97d
+EBUILD mongodb-1.6.5.ebuild 1915 RMD160 33ac48cb3a1bcd2b91ed5dca673f6452ff860894 SHA1 3e158fc5a22fd312c5856cfdfb18f71b025e3dd6 SHA256 f5a14f4a6bf101c0a369e0822941b75acb3817c48aa6e88e0ffd895922976ec3
+EBUILD mongodb-1.8.1.ebuild 1956 RMD160 99e439c4e805d4829f56df4f47a24951848572b6 SHA1 43efb1d4089448b885f99dae94c6eb4738b88363 SHA256 f841d6c025241880cc2e98df21a88395640b84ebc4a34b24825550194dfbc109
+MISC ChangeLog 4206 RMD160 3db4ce5c3390c05e5f3869238c1d078c2f7a50db SHA1 9ee4320739b46c3cc1eab130e8b0002877d10146 SHA256 65d01f0dd3574736dcd5bcc733d16ae8b6131a50816fc47292bed6cdfb8b6487
MISC metadata.xml 884 RMD160 f0cb7b3592708ec85696616af69b9bfc0e81e9c2 SHA1 de8f61e005e2c499c24084a0e0ab493c65a50c0c SHA256 e15990a373759e839063bd6bf698f0cc835bb4ef46352dbe50020d14335b91c7
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (GNU/Linux)
-iF4EAREIAAYFAk2TZ4gACgkQKiQSS7ZY+hMfUwD/Ue153E+OPjMkc+JRjI17lhst
-3+bZIxW/JH02CA1yds0A/3C26lZxyLjdbimrn9CaEte+/PQjfN9iLP/jlNqgKcBi
-=bXo7
+iF4EAREIAAYFAk2luaoACgkQKiQSS7ZY+hPGngEAhky4SFW5xSo1bbD6UWdmxnWG
+XSJCa/cMvgJEhuIbizIA/RYbSf5VQsedRekn72o1eUSvI9IenqN8qFibHHIXsNdd
+=TR+z
-----END PGP SIGNATURE-----
diff --git a/dev-db/mongodb/files/mongodb-1.2-modify-post-strip.patch b/dev-db/mongodb/files/mongodb-1.2-modify-post-strip.patch
deleted file mode 100644
index b10de0e14f84..000000000000
--- a/dev-db/mongodb/files/mongodb-1.2-modify-post-strip.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- SConstruct 2009-10-17 15:22:09.000000000 +0200
-+++ SConstruct.new 2009-10-17 15:23:31.000000000 +0200
-@@ -1240,8 +1240,6 @@
- fullInstallName = installDir + "/bin/" + name
-
- allBinaries += [ name ]
-- if solaris or linux:
-- e.AddPostAction( inst, e.Action( 'strip ' + fullInstallName ) )
-
- if linux and len( COMMAND_LINE_TARGETS ) == 1 and str( COMMAND_LINE_TARGETS[0] ) == "s3dist":
- e.AddPostAction( inst , checkGlibc )
diff --git a/dev-db/mongodb/files/mongodb-1.2-modify-testing.patch b/dev-db/mongodb/files/mongodb-1.2-modify-testing.patch
deleted file mode 100644
index 31bda47c0ce7..000000000000
--- a/dev-db/mongodb/files/mongodb-1.2-modify-testing.patch
+++ /dev/null
@@ -1,44 +0,0 @@
---- SConstruct.old 2009-10-17 15:26:14.000000000 +0200
-+++ SConstruct 2009-10-17 15:29:52.000000000 +0200
-@@ -995,15 +995,17 @@
- Exit( 1 )
-
- def ensureTestDirs():
-- ensureDir( "/tmp/unittest/" )
-- ensureDir( "/data/" )
-- ensureDir( "/data/db/" )
-+ ensureDir( "testdir/" )
-+ ensureDir( "testdir/tmp/" )
-+ ensureDir( "testdir/tmp/unittest/" )
-+ ensureDir( "testdir/data/" )
-+ ensureDir( "testdir/data/db/" )
-
- def testSetup( env , target , source ):
- ensureTestDirs()
-
- if len( COMMAND_LINE_TARGETS ) == 1 and str( COMMAND_LINE_TARGETS[0] ) == "test":
-- ensureDir( "/tmp/unittest/" );
-+ ensureDir( "testdir/tmp/unittest/" );
-
- addSmoketest( "smoke", [ add_exe( "test" ) ] , [ test[ 0 ].abspath ] )
- addSmoketest( "smokePerf", [ "perftest" ] , [ perftest[ 0 ].abspath ] )
-@@ -1072,7 +1074,7 @@
- mongodForTestsPort = "40000"
- import os
- ensureTestDirs()
-- dirName = "/data/db/sconsTests/"
-+ dirName = "testdir/data/db/sconsTests/"
- ensureDir( dirName )
- from subprocess import Popen
- mongodForTests = Popen( [ mongod[0].abspath, "--port", mongodForTestsPort, "--dbpath", dirName ] )
-
---- dbtests/dbtests.cpp 2009-10-17 16:40:46.000000000 +0200
-+++ dbtests/dbtests.cpp.new 2009-10-17 16:40:54.000000000 +0200
-@@ -22,6 +22,6 @@
- #include "dbtests.h"
-
- int main( int argc, char** argv ) {
-- return Suite::run(argc, argv, "/tmp/unittest");
-+ return Suite::run(argc, argv, "testdir/tmp/unittest");
- }
-
diff --git a/dev-db/mongodb/files/mongodb-1.4-modify-post-strip.patch b/dev-db/mongodb/files/mongodb-1.4-modify-post-strip.patch
deleted file mode 100644
index 5795c7e48925..000000000000
--- a/dev-db/mongodb/files/mongodb-1.4-modify-post-strip.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -ur mongodb-src-r1.3.3/SConstruct mongodb-src-r1.3.3.new/SConstruct
---- mongodb-src-r1.3.3/SConstruct 2010-03-02 07:37:07.000000000 -0800
-+++ mongodb-src-r1.3.3.new/SConstruct 2010-03-07 22:36:10.000000000 -0800
-@@ -1478,8 +1478,6 @@
- fullInstallName = installDir + "/bin/" + name
-
- allBinaries += [ name ]
-- if (solaris or linux) and (not GetOption("nostrip")):
-- e.AddPostAction( inst, e.Action( 'strip ' + fullInstallName ) )
-
- if linux and len( COMMAND_LINE_TARGETS ) == 1 and str( COMMAND_LINE_TARGETS[0] ) == "s3dist":
- e.AddPostAction( inst , checkGlibc )
diff --git a/dev-db/mongodb/files/mongodb-1.4-modify-testing.patch b/dev-db/mongodb/files/mongodb-1.4-modify-testing.patch
deleted file mode 100644
index eac7843d5c2f..000000000000
--- a/dev-db/mongodb/files/mongodb-1.4-modify-testing.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-diff -ur mongodb-src-r1.4.0/SConstruct mongodb-src-r1.4.0.new/SConstruct
---- mongodb-src-r1.4.0/SConstruct 2010-03-02 07:37:07.000000000 -0800
-+++ mongodb-src-r1.4.0.new/SConstruct 2010-03-07 22:40:02.000000000 -0800
-@@ -1211,15 +1211,17 @@
- Exit( 1 )
-
- def ensureTestDirs():
-- ensureDir( "/tmp/unittest/" )
-- ensureDir( "/data/" )
-- ensureDir( "/data/db/" )
-+ ensureDir( "testdir/" )
-+ ensureDir( "testdir/tmp" )
-+ ensureDir( "testdir/tmp/unittest/" )
-+ ensureDir( "testdir/data/" )
-+ ensureDir( "testdir/data/db/" )
-
- def testSetup( env , target , source ):
- ensureTestDirs()
-
- if len( COMMAND_LINE_TARGETS ) == 1 and str( COMMAND_LINE_TARGETS[0] ) == "test":
-- ensureDir( "/tmp/unittest/" );
-+ ensureDir( "testdir/tmp/unittest/" );
-
- addSmoketest( "smoke", [ add_exe( "test" ) ] , [ test[ 0 ].abspath ] )
- addSmoketest( "smokePerf", [ "perftest" ] , [ perftest[ 0 ].abspath ] )
-@@ -1297,7 +1299,7 @@
- mongodForTestsPort = "32000"
- import os
- ensureTestDirs()
-- dirName = "/data/db/sconsTests/"
-+ dirName = "testdir/data/db/sconsTests/"
- ensureDir( dirName )
- from subprocess import Popen
- mongodForTests = Popen( [ mongod[0].abspath, "--port", mongodForTestsPort, "--dbpath", dirName ] )
-diff -ur mongodb-src-r1.4.0/dbtests/dbtests.cpp mongodb-src-r1.4.0.new/dbtests/dbtests.cpp
---- mongodb-src-r1.4.0/dbtests/dbtests.cpp 2010-03-02 07:37:07.000000000 -0800
-+++ mongodb-src-r1.4.0.new/dbtests/dbtests.cpp 2010-03-07 22:40:37.000000000 -0800
-@@ -23,6 +23,6 @@
-
- int main( int argc, char** argv ) {
- static StaticObserver StaticObserver;
-- return Suite::run(argc, argv, "/tmp/unittest");
-+ return Suite::run(argc, argv, "testdir/tmp/unittest");
- }
diff --git a/dev-db/mongodb/files/mongodb-1.6-fix-scons.patch b/dev-db/mongodb/files/mongodb-1.6-fix-scons.patch
new file mode 100644
index 000000000000..342c36f01595
--- /dev/null
+++ b/dev-db/mongodb/files/mongodb-1.6-fix-scons.patch
@@ -0,0 +1,39 @@
+diff --git a/SConstruct b/SConstruct
+index e3046ff..529b19b 100644
+--- a/SConstruct
++++ b/SConstruct
+@@ -745,20 +745,19 @@ else:
+
+ if nix:
+ env.Append( CPPFLAGS="-fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch" )
+- if linux:
+- env.Append( CPPFLAGS=" -Werror " )
+ env.Append( CXXFLAGS=" -Wnon-virtual-dtor " )
++ env.Append( CXXFLAGS=os.environ['CXXFLAGS'])
++ env.Append( LINKFLAGS=os.environ['LDFLAGS'] )
+ env.Append( LINKFLAGS=" -fPIC -pthread -rdynamic" )
+ env.Append( LIBS=[] )
+
+ if linux and GetOption( "sharedclient" ):
+ env.Append( LINKFLAGS=" -Wl,--as-needed -Wl,-zdefs " )
++ env.Append( SHLINKFLAGS=" -Wl,-soname=libmongoclient.so " )
+
+ if debugBuild:
+ env.Append( CPPFLAGS=" -O0 -fstack-protector " );
+ env['ENV']['GLIBCXX_FORCE_NEW'] = 1; # play nice with valgrind
+- else:
+- env.Append( CPPFLAGS=" -O3" )
+
+ if debugLogging:
+ env.Append( CPPFLAGS=" -D_DEBUG" );
+@@ -972,8 +971,8 @@ def doConfigure( myenv , needPcre=True , shell=False ):
+
+ myCheckLib( J , True )
+ mozHeader = "js"
+- if bigLibString(myenv).find( "mozjs" ) >= 0:
+- mozHeader = "mozjs"
++ env.Append( CPPPATH=["/usr/include/nspr"] )
++ env.Append( CPPDEFINES=[ "XULRUNNER" ] )
+
+ if not conf.CheckHeader( mozHeader + "/jsapi.h" ):
+ if conf.CheckHeader( "jsapi.h" ):
diff --git a/dev-db/mongodb/files/mongodb-1.6.0-fix-scons.patch b/dev-db/mongodb/files/mongodb-1.6.0-fix-scons.patch
deleted file mode 100644
index 7122df8ec7b7..000000000000
--- a/dev-db/mongodb/files/mongodb-1.6.0-fix-scons.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-diff -urN mongodb-src-r1.6.0.orig/SConstruct mongodb-src-r1.6.0/SConstruct
---- mongodb-src-r1.6.0.orig/SConstruct 2010-08-05 15:32:06.000000000 +0200
-+++ mongodb-src-r1.6.0/SConstruct 2010-08-16 16:12:52.000000000 +0200
-@@ -745,8 +745,7 @@
-
- if nix:
- env.Append( CPPFLAGS="-fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch" )
-- if linux:
-- env.Append( CPPFLAGS=" -Werror " )
-+ env.Append( CXXFLAGS=os.environ['CXXFLAGS'])
- env.Append( CXXFLAGS=" -Wnon-virtual-dtor " )
- env.Append( LINKFLAGS=" -fPIC -pthread -rdynamic" )
- env.Append( LIBS=[] )
-@@ -757,8 +756,6 @@
- if debugBuild:
- env.Append( CPPFLAGS=" -O0 -fstack-protector " );
- env['ENV']['GLIBCXX_FORCE_NEW'] = 1; # play nice with valgrind
-- else:
-- env.Append( CPPFLAGS=" -O3" )
-
- if debugLogging:
- env.Append( CPPFLAGS=" -D_DEBUG" );
diff --git a/dev-db/mongodb/files/mongodb-1.8-fix-scons.patch b/dev-db/mongodb/files/mongodb-1.8-fix-scons.patch
new file mode 100644
index 000000000000..3d2996a35354
--- /dev/null
+++ b/dev-db/mongodb/files/mongodb-1.8-fix-scons.patch
@@ -0,0 +1,39 @@
+--- a/SConstruct 2011-04-06 06:40:13.000000000 +0200
++++ b/SConstruct 2011-04-10 15:50:52.696516582 +0200
+@@ -671,9 +671,10 @@
+ env.Append( CPPFLAGS="-fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch" )
+ # env.Append( " -Wconversion" ) TODO: this doesn't really work yet
+ if linux:
+- env.Append( CPPFLAGS=" -Werror " )
+ env.Append( CPPFLAGS=" -fno-builtin-memcmp " ) # glibc's memcmp is faster than gcc's
++ env.Append( CXXFLAGS=os.environ['CXXFLAGS'])
+ env.Append( CXXFLAGS=" -Wnon-virtual-dtor " )
++ env.Append( LINKFLAGS=os.environ['LDFLAGS'] )
+ env.Append( LINKFLAGS=" -fPIC -pthread -rdynamic" )
+ env.Append( LIBS=[] )
+
+@@ -683,12 +684,11 @@
+
+ if linux and has_option( "sharedclient" ):
+ env.Append( LINKFLAGS=" -Wl,--as-needed -Wl,-zdefs " )
++ env.Append( SHLINKFLAGS=" -Wl,-soname=libmongoclient.so " )
+
+ if debugBuild:
+ env.Append( CPPFLAGS=" -O0 -fstack-protector " );
+ env['ENV']['GLIBCXX_FORCE_NEW'] = 1; # play nice with valgrind
+- else:
+- env.Append( CPPFLAGS=" -O3" )
+ #env.Append( CPPFLAGS=" -fprofile-generate" )
+ #env.Append( LINKFLAGS=" -fprofile-generate" )
+ # then:
+@@ -911,8 +911,8 @@
+
+ myCheckLib( J , True )
+ mozHeader = "js"
+- if bigLibString(myenv).find( "mozjs" ) >= 0:
+- mozHeader = "mozjs"
++ env.Append( CPPPATH=["/usr/include/nspr"] )
++ env.Append( CPPDEFINES=[ "XULRUNNER" ] )
+
+ if not conf.CheckHeader( mozHeader + "/jsapi.h" ):
+ if conf.CheckHeader( "jsapi.h" ):
diff --git a/dev-db/mongodb/files/mongodb.confd b/dev-db/mongodb/files/mongodb.confd
index bc1660130ce4..9b3a43835271 100644
--- a/dev-db/mongodb/files/mongodb.confd
+++ b/dev-db/mongodb/files/mongodb.confd
@@ -1,11 +1,11 @@
# Mongodb essentials
MONGODB_EXEC="/usr/bin/mongod"
+MONGODB_RUN="/var/run/mongodb"
MONGODB_DATA="/var/lib/mongodb"
MONGODB_USER="mongodb"
-MONGODB_PID_FILE="/var/run/mongodb/mongodb.pid"
MONGODB_IP="127.0.0.1"
MONGODB_PORT="27017"
# Set extra options here, such as disabling the admin web server
-MONGODB_OPTIONS=""
+MONGODB_OPTIONS="--journal"
diff --git a/dev-db/mongodb/files/mongodb.initd b/dev-db/mongodb/files/mongodb.initd
index 482e311fcd6b..ac1bc31930ca 100644
--- a/dev-db/mongodb/files/mongodb.initd
+++ b/dev-db/mongodb/files/mongodb.initd
@@ -1,45 +1,33 @@
#!/sbin/runscript
-# Copyright 1999-2009 Gentoo Foundation
+# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/files/mongodb.initd,v 1.2 2010/05/21 06:39:57 lu_zero Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/files/mongodb.initd,v 1.3 2011/04/13 14:56:32 ultrabug Exp $
depend() {
need net
}
start() {
- ebegin "Starting ${SVCNAME}"
- if [ -z "$MONGODB_PID_FILE" ] ; then
- ewarn "MONGODB_PID_FILE must be set"
- return -1
- fi
- if [ -z "$MONGODB_USER" ] ; then
- ewarn "ERROR: MONGODB_USER must be set"
- return -1
- fi
-
- args=""
- if [ -n "$MONGODB_DATA" ] ; then
- args="$args --dbpath $MONGODB_DATA"
- fi
- if [ -n "$MONGODB_PORT" ] ; then
- args="$args --port $MONGODB_PORT"
- fi
- if [ -n "$MONGODB_IP" ] ; then
- args="$args --bind_ip $MONGODB_IP"
- fi
- if [ -n "$MONGODB_OPTIONS" ] ; then
- args="$args $MONGODB_OPTIONS"
- fi
+ mkdir -p ${MONGODB_RUN:-/var/run/mongodb}
+ chown ${MONGODB_USER:-mongodb}: ${MONGODB_RUN:-/var/run/mongodb}
- start-stop-daemon --background --start --user ${MONGODB_USER} --pidfile \
- "${MONGODB_PID_FILE}" --make-pidfile --exec ${MONGODB_EXEC} \
- -- ${args} run
+ ebegin "Starting ${SVCNAME}"
+ start-stop-daemon --background --start --make-pidfile \
+ --pidfile ${MONGODB_RUN:-/var/run/mongodb}/${SVCNAME}.pid \
+ --chuid ${MONGODB_USER:-mongodb} \
+ --exec ${MONGODB_EXEC:-/usr/bin/mongod} \
+ -- \
+ --bind_ip ${MONGODB_IP:-127.0.0.1} \
+ --port ${MONGODB_PORT:-27017} \
+ --dbpath ${MONGODB_DATA:-/var/lib/mongodb} \
+ --unixSocketPrefix ${MONGODB_RUN:-/var/run/mongodb} \
+ --logappend --logpath /var/log/mongodb/${SVCNAME}.log \
+ ${MONGODB_OPTIONS}
eend $?
}
stop() {
ebegin "Stopping ${SVCNAME}"
- start-stop-daemon --stop --exec ${MONGODB_EXEC} --pidfile ${MONGODB_PID_FILE}
- eend $? "Failed to stop ${SVCNAME}"
+ start-stop-daemon --stop --pidfile ${MONGODB_RUN:-/var/run/mongodb}/${SVCNAME}.pid
+ eend $?
}
diff --git a/dev-db/mongodb/files/mongos.confd b/dev-db/mongodb/files/mongos.confd
new file mode 100644
index 000000000000..8ac0ebcd655b
--- /dev/null
+++ b/dev-db/mongodb/files/mongos.confd
@@ -0,0 +1,13 @@
+# Mongos essentials
+MONGOS_EXEC="/usr/bin/mongos"
+MONGOS_RUN="/var/run/mongodb"
+MONGOS_USER="mongodb"
+
+MONGOS_IP="127.0.0.1"
+MONGOS_PORT="27018"
+
+# 1 to 3 comma separated config servers (mandatory)
+MONGOS_CONFIGDB=""
+
+# Set extra options here
+MONGOS_OPTIONS=""
diff --git a/dev-db/mongodb/files/mongos.initd b/dev-db/mongodb/files/mongos.initd
new file mode 100644
index 000000000000..9279c4fc9993
--- /dev/null
+++ b/dev-db/mongodb/files/mongos.initd
@@ -0,0 +1,43 @@
+#!/sbin/runscript
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/files/mongos.initd,v 1.1 2011/04/13 14:56:32 ultrabug Exp $
+
+depend() {
+ need net
+}
+
+checkconfig() {
+ if [ -z "${MONGOS_CONFIGDB}" ]; then
+ eerror "MONGOS_CONFIGDB is not defined, check your configuration file !"
+ return 1
+ fi
+ return 0
+}
+
+start() {
+ checkconfig || return 1
+
+ mkdir -p ${MONGOS_RUN:-/var/run/mongodb}
+ chown ${MONGOS_USER:-mongodb}: ${MONGOS_RUN:-/var/run/mongodb}
+
+ ebegin "Starting ${SVCNAME}"
+ start-stop-daemon --background --start --make-pidfile \
+ --pidfile ${MONGOS_RUN:-/var/run/mongodb}/${SVCNAME}.pid \
+ --chuid ${MONGOS_USER:-mongodb} \
+ --exec ${MONGOS_EXEC:-/usr/bin/mongos} \
+ -- \
+ --bind_ip ${MONGOS_IP:-127.0.0.1} \
+ --port ${MONGOS_PORT:-27018} \
+ --unixSocketPrefix ${MONGOS_RUN:-/var/run/mongodb} \
+ --logappend --logpath /var/log/mongodb/${SVCNAME}.log \
+ --configdb ${MONGOS_CONFIGDB} \
+ ${MONGOS_OPTIONS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping ${SVCNAME}"
+ start-stop-daemon --stop --pidfile ${MONGOS_RUN:-/var/run/mongodb}/${SVCNAME}.pid
+ eend $?
+} \ No newline at end of file
diff --git a/dev-db/mongodb/mongodb-1.2.4.ebuild b/dev-db/mongodb/mongodb-1.2.4.ebuild
deleted file mode 100644
index 257b98a6cb7c..000000000000
--- a/dev-db/mongodb/mongodb-1.2.4.ebuild
+++ /dev/null
@@ -1,61 +0,0 @@
-# Copyright 1999-2011 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/mongodb-1.2.4.ebuild,v 1.2 2011/03/30 17:25:19 ultrabug Exp $
-
-EAPI="2"
-
-inherit eutils versionator
-
-MY_PATCHVER=$(get_version_component_range 1-2)
-MY_P="${PN}-src-r${PV}"
-
-DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
-HOMEPAGE="http://www.mongodb.org"
-SRC_URI="http://downloads.mongodb.org/src/${MY_P}.tar.gz"
-
-LICENSE="AGPL-3 Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE=""
-
-RDEPEND="dev-lang/spidermonkey[unicode]
- dev-libs/boost
- dev-libs/libpcre"
-
-DEPEND="${RDEPEND}
- >=dev-util/scons-1.2.0-r1"
-
-# Must change this on every upgrade
-S="${WORKDIR}/${MY_P}"
-
-pkg_setup() {
- enewgroup mongodb
- enewuser mongodb -1 -1 /var/lib/${PN} mongodb
-}
-
-src_prepare() {
- epatch "${FILESDIR}"/"${PN}"-"${MY_PATCHVER}"-modify-*.patch
-}
-
-src_compile() {
- scons ${MAKEOPTS} all || die "Compile failed"
-}
-
-src_install() {
- scons ${MAKEOPTS} install --prefix="${D}"/usr || die "Install failed"
-
- for x in /var/{lib,log,run}/${PN}; do
- dodir "${x}" || die "Install failed"
- fowners mongodb:mongodb "${x}"
- done
-
- doman debian/mongo*.1 || die "Install failed"
- dodoc README docs/building.md
-
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die "Install failed"
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die "Install failed"
-}
-
-src_test() {
- scons ${MAKEOPTS} smoke test || die "Tests failed"
-}
diff --git a/dev-db/mongodb/mongodb-1.4.4.ebuild b/dev-db/mongodb/mongodb-1.4.4.ebuild
deleted file mode 100644
index 937ee4a01d25..000000000000
--- a/dev-db/mongodb/mongodb-1.4.4.ebuild
+++ /dev/null
@@ -1,61 +0,0 @@
-# Copyright 1999-2011 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/mongodb-1.4.4.ebuild,v 1.2 2011/03/30 17:25:19 ultrabug Exp $
-
-EAPI="2"
-
-inherit eutils versionator
-
-MY_PATCHVER=$(get_version_component_range 1-2)
-MY_P="${PN}-src-r${PV}"
-
-DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
-HOMEPAGE="http://www.mongodb.org"
-SRC_URI="http://downloads.mongodb.org/src/${MY_P}.tar.gz"
-
-LICENSE="AGPL-3 Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE=""
-
-RDEPEND="dev-lang/spidermonkey[unicode]
- dev-libs/boost
- dev-libs/libpcre"
-
-DEPEND="${RDEPEND}
- >=dev-util/scons-1.2.0-r1"
-
-# Must change this on every upgrade
-S="${WORKDIR}/${MY_P}"
-
-pkg_setup() {
- enewgroup mongodb
- enewuser mongodb -1 -1 /var/lib/${PN} mongodb
-}
-
-src_prepare() {
- epatch "${FILESDIR}"/"${PN}"-"${MY_PATCHVER}"-modify-*.patch
-}
-
-src_compile() {
- scons ${MAKEOPTS} all || die "Compile failed"
-}
-
-src_install() {
- scons ${MAKEOPTS} install --prefix="${D}"/usr || die "Install failed"
-
- for x in /var/{lib,log,run}/${PN}; do
- dodir "${x}" || die "Install failed"
- fowners mongodb:mongodb "${x}"
- done
-
- doman debian/mongo*.1 || die "Install failed"
- dodoc README docs/building.md
-
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die "Install failed"
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die "Install failed"
-}
-
-src_test() {
- scons ${MAKEOPTS} smoke test || die "Tests failed"
-}
diff --git a/dev-db/mongodb/mongodb-1.5.5.ebuild b/dev-db/mongodb/mongodb-1.5.5.ebuild
deleted file mode 100644
index 88aa7b277050..000000000000
--- a/dev-db/mongodb/mongodb-1.5.5.ebuild
+++ /dev/null
@@ -1,63 +0,0 @@
-# Copyright 1999-2011 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/mongodb-1.5.5.ebuild,v 1.3 2011/03/30 17:25:19 ultrabug Exp $
-
-EAPI="2"
-
-inherit eutils versionator
-
-MY_PATCHVER=$(get_version_component_range 1-2)
-MY_P="${PN}-src-r${PV}"
-
-DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
-HOMEPAGE="http://www.mongodb.org"
-SRC_URI="http://downloads.mongodb.org/src/${MY_P}.tar.gz"
-
-LICENSE="AGPL-3 Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE=""
-
-RDEPEND="dev-lang/spidermonkey[unicode]
- dev-libs/boost
- dev-libs/libpcre"
-
-DEPEND="${RDEPEND}
- >=dev-util/scons-1.2.0-r1
- sys-libs/readline
- sys-libs/ncurses"
-
-# Must change this on every upgrade
-S="${WORKDIR}/${MY_P}"
-
-pkg_setup() {
- enewgroup mongodb
- enewuser mongodb -1 -1 /var/lib/${PN} mongodb
-}
-
-#src_prepare() {
-# epatch "${FILESDIR}"/"${PN}"-"${MY_PATCHVER}"-modify-*.patch
-#}
-
-src_compile() {
- scons ${MAKEOPTS} all || die "Compile failed"
-}
-
-src_install() {
- scons ${MAKEOPTS} --nostrip install --prefix="${D}"/usr || die "Install failed"
-
- for x in /var/{lib,log,run}/${PN}; do
- dodir "${x}" || die "Install failed"
- fowners mongodb:mongodb "${x}"
- done
-
- doman debian/mongo*.1 || die "Install failed"
- dodoc README docs/building.md
-
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die "Install failed"
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die "Install failed"
-}
-
-src_test() {
- scons ${MAKEOPTS} smoke --smokedbprefix='testdir' test || die "Tests failed"
-}
diff --git a/dev-db/mongodb/mongodb-1.6.0.ebuild b/dev-db/mongodb/mongodb-1.6.0.ebuild
deleted file mode 100644
index 465d4f947f1d..000000000000
--- a/dev-db/mongodb/mongodb-1.6.0.ebuild
+++ /dev/null
@@ -1,78 +0,0 @@
-# Copyright 1999-2011 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/mongodb-1.6.0.ebuild,v 1.3 2011/03/30 17:25:19 ultrabug Exp $
-
-EAPI="2"
-
-inherit eutils versionator
-
-MY_PATCHVER=$(get_version_component_range 1-2)
-MY_P="${PN}-src-r${PV}"
-
-DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
-HOMEPAGE="http://www.mongodb.org"
-SRC_URI="http://downloads.mongodb.org/src/${MY_P}.tar.gz"
-
-LICENSE="AGPL-3 Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE="v8"
-
-RDEPEND="!v8? ( dev-lang/spidermonkey[unicode] )
- v8? ( dev-lang/v8 )
- dev-libs/boost
- dev-libs/libpcre"
-
-DEPEND="${RDEPEND}
- >=dev-util/scons-1.2.0-r1
- sys-libs/readline
- sys-libs/ncurses"
-
-# Must change this on every upgrade
-S="${WORKDIR}/${MY_P}"
-
-pkg_setup() {
- enewgroup mongodb
- enewuser mongodb -1 -1 /var/lib/${PN} mongodb
-
- scons_opts="${MAKEOPTS}"
- if use v8; then
- scons_opts+=" --usev8"
- else
- scons_opts+=" --usesm"
- fi
-}
-
-src_prepare() {
- epatch "${FILESDIR}/${P}-fix-scons.patch"
-#} epatch "${FILESDIR}"/"${PN}"-"${MY_PATCHVER}"-modify-*.patch
-
- if use v8; then
- # Suppress known test failure with v8:
- # http://jira.mongodb.org/browse/SERVER-1147
- sed -e '/add< NumberLong >/d' -i dbtests/jstests.cpp || die
- fi
-}
-
-src_compile() {
- scons ${scons_opts} all || die "Compile failed"
-}
-
-src_install() {
- scons ${scons_opts} --full --nostrip install --prefix="${D}"/usr || die "Install failed"
-
- for x in /var/{lib,log,run}/${PN}; do
- dodir "${x}" || die "Install failed"
- fowners mongodb:mongodb "${x}"
- done
-
- doman debian/mongo*.1 || die "Install failed"
- dodoc README docs/building.md
-
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die "Install failed"
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die "Install failed"
-}
-
-src_test() {
- scons ${scons_opts} smoke --smokedbprefix='testdir' test || die "Tests failed"
-}
diff --git a/dev-db/mongodb/mongodb-1.6.5.ebuild b/dev-db/mongodb/mongodb-1.6.5.ebuild
new file mode 100644
index 000000000000..d85f1e61e785
--- /dev/null
+++ b/dev-db/mongodb/mongodb-1.6.5.ebuild
@@ -0,0 +1,82 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/mongodb-1.6.5.ebuild,v 1.1 2011/04/13 14:56:32 ultrabug Exp $
+
+EAPI=4
+SCONS_MIN_VERSION="1.2.0"
+
+inherit eutils multilib scons-utils versionator
+
+MY_P=${PN}-src-r${PV/_rc/-rc}
+
+DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
+HOMEPAGE="http://www.mongodb.org"
+SRC_URI="http://downloads.mongodb.org/src/${MY_P}.tar.gz"
+
+LICENSE="AGPL-3 Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="static-libs v8"
+
+RDEPEND="!v8? ( >=dev-lang/spidermonkey-1.9 )
+ v8? ( dev-lang/v8 )
+ dev-libs/boost
+ dev-libs/libpcre[cxx]
+ net-libs/libpcap"
+DEPEND="${RDEPEND}
+ sys-libs/readline
+ sys-libs/ncurses"
+
+S=${WORKDIR}/${MY_P}
+
+pkg_setup() {
+ enewgroup mongodb
+ enewuser mongodb -1 -1 /var/lib/${PN} mongodb
+
+ scons_opts=" --sharedclient"
+ if use v8; then
+ scons_opts+=" --usev8"
+ else
+ scons_opts+=" --usesm"
+ fi
+}
+
+src_prepare() {
+ epatch "${FILESDIR}/${PN}-1.6-fix-scons.patch"
+}
+
+src_compile() {
+ escons ${scons_opts} all
+}
+
+src_install() {
+ escons ${scons_opts} --full --nostrip install --prefix="${D}"/usr
+
+ use static-libs || rm "${D}/usr/$(get_libdir)/libmongoclient.a"
+
+ for x in /var/{lib,log,run}/${PN}; do
+ keepdir "${x}"
+ fowners mongodb:mongodb "${x}"
+ done
+
+ doman debian/mongo*.1
+ dodoc README docs/building.md
+
+ newinitd "${FILESDIR}/${PN}.initd" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd" ${PN}
+
+ # Remove unsupported options
+ sed -i -e '/--unixSocketPrefix/d' "${D}/etc/init.d/${PN}"
+ sed -i -e 's/--journal//g' "${D}/etc/conf.d/${PN}"
+}
+
+src_test() {
+ escons ${scons_opts} smoke --smokedbprefix='testdir' test
+}
+
+pkg_postinst() {
+ if [[ ${REPLACING_VERSIONS} < 1.6 ]]; then
+ ewarn "You just upgraded from a previous version of mongodb !"
+ ewarn "Make sure you run 'mongod --upgrade' before using this version."
+ fi
+}
diff --git a/dev-db/mongodb/mongodb-1.8.1.ebuild b/dev-db/mongodb/mongodb-1.8.1.ebuild
new file mode 100644
index 000000000000..5f6f777beeb2
--- /dev/null
+++ b/dev-db/mongodb/mongodb-1.8.1.ebuild
@@ -0,0 +1,82 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mongodb/mongodb-1.8.1.ebuild,v 1.1 2011/04/13 14:56:32 ultrabug Exp $
+
+EAPI=4
+SCONS_MIN_VERSION="1.2.0"
+
+inherit eutils multilib scons-utils versionator
+
+MY_P=${PN}-src-r${PV/_rc/-rc}
+
+DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
+HOMEPAGE="http://www.mongodb.org"
+SRC_URI="http://downloads.mongodb.org/src/${MY_P}.tar.gz"
+
+LICENSE="AGPL-3 Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="static-libs v8"
+
+RDEPEND="!v8? ( >=dev-lang/spidermonkey-1.9 )
+ v8? ( dev-lang/v8 )
+ dev-libs/boost
+ dev-libs/libpcre[cxx]
+ net-libs/libpcap"
+DEPEND="${RDEPEND}
+ sys-libs/readline
+ sys-libs/ncurses"
+
+S=${WORKDIR}/${MY_P}
+
+pkg_setup() {
+ enewgroup mongodb
+ enewuser mongodb -1 -1 /var/lib/${PN} mongodb
+
+ scons_opts=" --sharedclient"
+ if use v8; then
+ scons_opts+=" --usev8"
+ else
+ scons_opts+=" --usesm"
+ fi
+}
+
+src_prepare() {
+ epatch "${FILESDIR}/${PN}-1.8-fix-scons.patch"
+}
+
+src_compile() {
+ escons ${scons_opts} all
+}
+
+src_install() {
+ escons ${scons_opts} --full --nostrip install --prefix="${D}"/usr
+
+ use static-libs || rm "${D}/usr/$(get_libdir)/libmongoclient.a"
+
+ for x in /var/{lib,log,run}/${PN}; do
+ keepdir "${x}"
+ fowners mongodb:mongodb "${x}"
+ done
+
+ doman debian/mongo*.1
+ dodoc README docs/building.md
+
+ newinitd "${FILESDIR}/${PN}.initd" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd" ${PN}
+ newinitd "${FILESDIR}/${PN/db/s}.initd" ${PN/db/s}
+ newconfd "${FILESDIR}/${PN/db/s}.confd" ${PN/db/s}
+}
+
+src_test() {
+ escons ${scons_opts} test
+ "${S}"/test --dbpath=unittest || die
+}
+
+pkg_postinst() {
+ if [[ ${REPLACING_VERSIONS} < 1.8 ]]; then
+ ewarn "You just upgraded from a previous version of mongodb !"
+ ewarn "Make sure you run 'mongod --upgrade' before using this version."
+ fi
+ elog "Journaling is now enabled by default, see /etc/conf.d/${PN}.conf"
+}