From 9100ad3e8f2cbb27e455d44794c75f220e5b7f05 Mon Sep 17 00:00:00 2001 From: James Emerton Date: Fri, 10 Jan 2014 11:56:14 -0800 Subject: [PATCH] Use get_ext_fullpath() for -outputresource The manifest fixup was relying on the extension name being "_psycopg.pyd" which effectively prevents building with --debug as the extension name becomes "_psycopg_d.pyd" in this instance. --- setup.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/setup.py b/setup.py index 83d734a3..56aad293 100644 --- a/setup.py +++ b/setup.py @@ -293,12 +293,11 @@ class psycopg_build_ext(build_ext): manifest = '_psycopg.vc9.x86.manifest' if platform == 'win-amd64': manifest = '_psycopg.vc9.amd64.manifest' + ext_path = self.get_ext_fullpath(extension.name) self.compiler.spawn( ['mt.exe', '-nologo', '-manifest', os.path.join('psycopg', manifest), - '-outputresource:%s;2' % ( - os.path.join(self.build_lib, - 'psycopg2', '_psycopg.pyd'))]) + '-outputresource:%s;2' % ext_path]) def finalize_win32(self): """Finalize build system configuration on win32 platform."""