summaryrefslogtreecommitdiff
path: root/giscanner/ccompiler.py
diff options
context:
space:
mode:
authorOlivier CrĂȘte <olivier.crete@collabora.com>2018-11-05 14:57:21 -0500
committerOlivier CrĂȘte <olivier.crete@collabora.com>2018-11-05 17:03:33 -0500
commit4996dbe140889c27702aba155e08d6e77213f98b (patch)
treeae7a954fa87ec05770dd3b60934c96539e1f3383 /giscanner/ccompiler.py
parent1ff23a5d290de418655e7e67e522eacbda317115 (diff)
downloadgobject-introspection-4996dbe140889c27702aba155e08d6e77213f98b.tar.gz
scanner: Pass library paths before the -l itself
Without this, it will probably take the system library instead of the one that we are trying to test.
Diffstat (limited to 'giscanner/ccompiler.py')
-rw-r--r--giscanner/ccompiler.py22
1 files changed, 11 insertions, 11 deletions
diff --git a/giscanner/ccompiler.py b/giscanner/ccompiler.py
index c0038285..78e3825f 100644
--- a/giscanner/ccompiler.py
+++ b/giscanner/ccompiler.py
@@ -133,17 +133,6 @@ class CCompiler(object):
if sys.platform != 'darwin':
args.append('-Wl,--no-as-needed')
- for library in libraries + extra_libraries:
- if self.check_is_msvc():
- # Note that Visual Studio builds do not use libtool!
- if library != 'm':
- args.append(library + '.lib')
- else:
- if library.endswith(".la"): # explicitly specified libtool library
- args.append(library)
- else:
- args.append('-l' + library)
-
for library_path in libpaths:
# The dumper program needs to look for dynamic libraries
# in the library paths first
@@ -161,6 +150,17 @@ class CCompiler(object):
runtime_paths.append(library_path)
+ for library in libraries + extra_libraries:
+ if self.check_is_msvc():
+ # Note that Visual Studio builds do not use libtool!
+ if library != 'm':
+ args.append(library + '.lib')
+ else:
+ if library.endswith(".la"): # explicitly specified libtool library
+ args.append(library)
+ else:
+ args.append('-l' + library)
+
for envvar in runtime_path_envvar:
if envvar in os.environ:
os.environ[envvar] = \