[pywin32-checkins] pywin32 setup.py,1.54,1.55
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Mark H. <mha...@us...> - 2007-02-15 13:07:53
|
Update of /cvsroot/pywin32/pywin32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30291 Modified Files: setup.py Log Message: Create a .pch in release builds (but don't attempt to distribute them!) Index: setup.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/setup.py,v retrieving revision 1.54 retrieving revision 1.55 diff -C2 -d -r1.54 -r1.55 *** setup.py 3 Feb 2007 21:11:13 -0000 1.54 --- setup.py 15 Feb 2007 13:07:48 -0000 1.55 *************** *** 688,698 **** ext.extra_compile_args.append("/Fp"+pch_name) - # Put our DLL base address in. - if not self.mingw32: - base = ext.base_address - if not base: - base = dll_base_addresses[ext.name] - ext.extra_link_args.append("/BASE:0x%x" % (base,)) - # some source files are compiled for different extensions # with special defines. So we cannot use a shared --- 688,691 ---- *************** *** 702,705 **** --- 695,722 ---- # 2.3+ - Wrong dir, numbered name self.build_temp = os.path.join(self.build_temp, ext.name) + + if not self.mingw32: + # Put our DLL base address in. + base = ext.base_address + if not base: + base = dll_base_addresses[ext.name] + ext.extra_link_args.append("/BASE:0x%x" % (base,)) + + # like Python, always use debug info, even in release builds + # (note the compiler doesn't include debug info, so you only get + # basic info - but its better than nothing!) + # For now use the temp dir - later we may package them, so should + # maybe move them next to the output file. + # ack - but fails with obscure errors in py23 :( + if sys.version_info > (2,4): + pch_dir = os.path.join(self.build_temp) + if not self.debug: + ext.extra_compile_args.append("/Zi") + ext.extra_compile_args.append("/Fd%s\%s_vc.pdb" % + (pch_dir, ext.name)) + ext.extra_link_args.append("/DEBUG") + ext.extra_link_args.append("/PDB:%s\%s.pdb" % + (pch_dir, ext.name)) + self.swig_cpp = True try: |