Gentoo Archives: gentoo-commits

From: "Alexys Jacob (ultrabug)" <ultrabug@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-db/mongodb/files: mongodb-2.0.3-fix-scons.patch
Date: Wed, 29 Feb 2012 11:31:32
Message-Id: 20120229113111.D7F2B2004C@flycatcher.gentoo.org
1 ultrabug 12/02/29 11:31:11
2
3 Added: mongodb-2.0.3-fix-scons.patch
4 Log:
5 version bump, drop old
6
7 (Portage version: 2.1.10.49/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.1 dev-db/mongodb/files/mongodb-2.0.3-fix-scons.patch
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/mongodb/files/mongodb-2.0.3-fix-scons.patch?rev=1.1&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/mongodb/files/mongodb-2.0.3-fix-scons.patch?rev=1.1&content-type=text/plain
14
15 Index: mongodb-2.0.3-fix-scons.patch
16 ===================================================================
17 --- a/SConstruct 2012-02-27 01:44:09.000000000 +0100
18 +++ b/SConstruct 2012-02-29 12:19:27.806016101 +0100
19 @@ -700,7 +700,7 @@
20 env["CXX"] = "distcc " + env["CXX"]
21
22 # -Winvalid-pch Warn if a precompiled header (see Precompiled Headers) is found in the search path but can't be used.
23 - env.Append( CPPFLAGS="-fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch" )
24 + env.Append( CPPFLAGS="-fPIC -fno-strict-aliasing -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch" )
25 # env.Append( " -Wconversion" ) TODO: this doesn't really work yet
26 if linux:
27 env.Append( CPPFLAGS=" -Werror " )
28 @@ -708,7 +708,9 @@
29 env.Append( CPPFLAGS=" -fno-builtin-memcmp " ) # glibc's memcmp is faster than gcc's
30
31 env.Append( CPPDEFINES="_FILE_OFFSET_BITS=64" )
32 + env.Append( CXXFLAGS=os.environ['CXXFLAGS'])
33 env.Append( CXXFLAGS=" -Wnon-virtual-dtor " )
34 + env.Append( LINKFLAGS=os.environ['LDFLAGS'] )
35 env.Append( LINKFLAGS=" -fPIC -pthread -rdynamic" )
36 env.Append( LIBS=[] )
37
38 @@ -718,12 +720,13 @@
39
40 if linux and has_option( "sharedclient" ):
41 env.Append( LINKFLAGS=" -Wl,--as-needed -Wl,-zdefs " )
42 + env.Append( SHLINKFLAGS=" -Wl,-soname=libmongoclient.so " )
43
44 if debugBuild:
45 env.Append( CPPFLAGS=" -O0 -fstack-protector " );
46 env['ENV']['GLIBCXX_FORCE_NEW'] = 1; # play nice with valgrind
47 else:
48 - env.Append( CPPFLAGS=" -O3 " )
49 + env.Append( CXXFLAGS=" -O3 " )
50 #env.Append( CPPFLAGS=" -fprofile-generate" )
51 #env.Append( LINKFLAGS=" -fprofile-generate" )
52 # then:
53 @@ -827,14 +830,16 @@
54 binaries = ['python2.5', 'python2.6', 'python2.7', 'python25', 'python26', 'python27', 'python']
55 for binary in binaries:
56 try:
57 - # py-2.4 compatible replacement for shell backticks
58 - out, err = subprocess.Popen([binary, '-V'], stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()
59 - for stream in (out, err):
60 - match = version.search(stream)
61 - if match:
62 - versiontuple = tuple(map(int, match.group(1).split('.')))
63 - if versiontuple >= (2, 5):
64 - return binary
65 + for path in smokeEnv['ENV']['PATH'].split(':'):
66 + if os.path.isfile( '%s/%s' % (path, binary) ):
67 + # py-2.4 compatible replacement for shell backticks
68 + out, err = subprocess.Popen([binary, '-V'], stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()
69 + for stream in (out, err):
70 + match = version.search(stream)
71 + if match:
72 + versiontuple = tuple(map(int, match.group(1).split('.')))
73 + if versiontuple >= (2, 5):
74 + return binary
75 except:
76 pass
77 # if that all fails, fall back to "python"