summaryrefslogtreecommitdiff
path: root/buildtools/wafsamba/samba_autoconf.py
diff options
context:
space:
mode:
Diffstat (limited to 'buildtools/wafsamba/samba_autoconf.py')
-rw-r--r--buildtools/wafsamba/samba_autoconf.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/buildtools/wafsamba/samba_autoconf.py b/buildtools/wafsamba/samba_autoconf.py
index 1ea818ef30..6ed719a80a 100644
--- a/buildtools/wafsamba/samba_autoconf.py
+++ b/buildtools/wafsamba/samba_autoconf.py
@@ -471,7 +471,9 @@ def library_flags(self, libs):
inc_path = getattr(self.env, 'CPPPATH_%s' % lib.upper(), [])
lib_path = getattr(self.env, 'LIBPATH_%s' % lib.upper(), [])
ccflags.extend(['-I%s' % i for i in inc_path])
- ldflags.extend(['-L%s' % l for l in lib_path])
+ # note that we do not add the -L in here, as that is added by the waf
+ # core. Adding it here would just change the order that it is put on the link line
+ # which can cause system paths to be added before internal libraries
extra_ccflags = TO_LIST(getattr(self.env, 'CCFLAGS_%s' % lib.upper(), []))
extra_ldflags = TO_LIST(getattr(self.env, 'LDFLAGS_%s' % lib.upper(), []))
ccflags.extend(extra_ccflags)