]> granicus.if.org Git - pdns/commitdiff
make sure we move static /usr/lib archives to the *end* of the commandline, plus...
authorBert Hubert <bert.hubert@netherlabs.nl>
Tue, 6 Nov 2012 08:53:52 +0000 (08:53 +0000)
committerBert Hubert <bert.hubert@netherlabs.nl>
Tue, 6 Nov 2012 08:53:52 +0000 (08:53 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@2853 d19b8d6e-7fed-0310-83ef-9ca221ded41b

build-scripts/semistaticg++

index 4a7f1a0c12398e6806fbcd7beb5effbb7d04dd44..68e149852f1884ac05541eff1cbb1c67f4062a94 100755 (executable)
@@ -10,10 +10,10 @@ otherargs = []
 for arg in args:
        if arg == '-static':
                continue
-       if arg.startswith('-l') and arg not in ('-lm','-ldl','-lpthread'):
+       if arg.startswith('/usr/lib') or (arg.startswith('-l') and arg not in ('-lm','-ldl','-lpthread')):
                libs.append(arg)
        else:
                otherargs.append(arg)
 
-gargv=['gcc']+otherargs+['-Wl,-Bstatic']+libs+['-lstdc++','-Wl,-Bdynamic','-static-libgcc']
+gargv=['gcc']+otherargs+['-Wl,-Bstatic']+libs+['-lstdc++','-Wl,-Bdynamic','-static-libgcc','-lm']
 os.execvp('gcc', gargv)