[pywin32-checkins] pywin32 setup.py,1.52,1.52.2.1
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Sidnei da S. <dre...@us...> - 2006-12-21 23:17:16
|
Update of /cvsroot/pywin32/pywin32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19745 Modified Files: Tag: AMD64 setup.py Log Message: - Initial work on AMD64 support Index: setup.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/setup.py,v retrieving revision 1.52 retrieving revision 1.52.2.1 diff -C2 -d -r1.52 -r1.52.2.1 *** setup.py 23 Sep 2006 00:31:53 -0000 1.52 --- setup.py 21 Dec 2006 23:17:15 -0000 1.52.2.1 *************** *** 215,219 **** sources.extend(self.get_source_files(dsp_file)) extra_link_args = extra_link_args or [] ! extra_link_args.append("/MACHINE:ix86") # Some of our swigged files behave differently in distutils vs # MSVC based builds. Always define DISTUTILS_BUILD so they can tell. --- 215,222 ---- sources.extend(self.get_source_files(dsp_file)) extra_link_args = extra_link_args or [] ! if get_build_architecture() in ('AMD64',): ! extra_link_args.append("/MACHINE:AMD64") ! else: ! extra_link_args.append("/MACHINE:ix86") # Some of our swigged files behave differently in distutils vs # MSVC based builds. Always define DISTUTILS_BUILD so they can tell. *************** *** 388,391 **** --- 391,396 ---- self.include_dirs.insert(0, extra) extra = os.path.join(sdk_dir, 'lib') + if get_build_architecture() in ('AMD64',): + extra = os.path.join(extra, 'AMD64') if extra not in self.library_dirs and os.path.isdir(extra): self.library_dirs.insert(0, extra) *************** *** 435,439 **** # module method in early Python versions get_msvc_paths = msvccompiler.get_msvc_paths ! look_dirs = self.include_dirs + get_msvc_paths("include") for h in ext.optional_headers: for d in look_dirs: --- 440,444 ---- # module method in early Python versions get_msvc_paths = msvccompiler.get_msvc_paths ! look_dirs = self.include_dirs # + get_msvc_paths("include") for h in ext.optional_headers: for d in look_dirs: *************** *** 457,460 **** --- 462,466 ---- patched_libs.append(os.path.splitext(os.path.basename(found))[0]) # axdebug struggles under debug builds - worry about that when I care :) + if ext.name == 'axdebug': return 'aye' if sys.hexversion < 0x2040000 and ext.name == 'axdebug' and self.debug: return "axdebug doesn't build in VC6 debug builds (irony!)" *************** *** 682,685 **** --- 688,695 ---- self.current_extension = ext + # Enable 64-bit porting warnings + if get_build_architecture() in ('AMD64',): + ext.extra_compile_args.append("/Wp64") + if not self.mingw32 and ext.pch_header: ext.extra_compile_args = ext.extra_compile_args or [] *************** *** 872,875 **** --- 882,890 ---- orig_new_compiler = ccompiler.new_compiler ccompiler.new_compiler = my_new_compiler + try: + get_build_architecture = msvccompiler.get_build_architecture + except AttributeError: + def get_build_architecture(): + return "Intel" class my_compiler(msvccompiler.MSVCCompiler): |