diff –git a/giscanner/ccompiler.py b/giscanner/ccompiler.py index a8bd5b13..f3949f24 100644 — a/giscanner/ccompiler.py +++ b/giscanner/ccompiler.py @@ -74,6 +74,7 @@ class CCompiler(object):

else:
    self.compiler = distutils.ccompiler.new_compiler(compiler=compiler_name)
customize_compiler(self.compiler)

+ self.compiler.exe_extension = '.exe'

# customize_compiler() from distutils only does customization
# for 'unix' compiler type.  Also, avoid linking to msvcrxx.dll

@@ -243,6 +244,7 @@ class CCompiler(object):

includes.extend(include_paths)
extra_postargs.extend(extra_args)

+ extra_postargs.append('-fno-stack-protector')

return self.compiler.compile(sources=source,
                             macros=macros,

@@ -285,7 +287,9 @@ class CCompiler(object):

    args.extend(libtool)
    args.append('--mode=execute')
args.extend([os.environ.get('DLLTOOL', 'dlltool.exe'), '--identify'])

+ search_dirs_args = shlex.split(self.compiler_cmd) + search_dirs_args += ['-print-search-dirs'] + proc = subprocess.Popen(search_dirs_args,

                        stdout=subprocess.PIPE)
o, e = proc.communicate()
libsearch = options.library_paths