Author: mattip <[email protected]>
Branch:
Changeset: r83445:cfbb442ae368
Date: 2016-03-30 23:56 +0300
http://bitbucket.org/pypy/pypy/changeset/cfbb442ae368/
Log: merge branch which fixes translation when cwd != pypy/goal
diff --git a/pypy/doc/whatsnew-head.rst b/pypy/doc/whatsnew-head.rst
--- a/pypy/doc/whatsnew-head.rst
+++ b/pypy/doc/whatsnew-head.rst
@@ -31,4 +31,7 @@
.. branch: jit-leaner-frontend
Improve the tracing speed in the frontend as well as heapcache by using a more
compact representation
-of traces
\ No newline at end of file
+of traces
+
+.. branch: win32-lib-name
+
diff --git a/pypy/goal/targetpypystandalone.py
b/pypy/goal/targetpypystandalone.py
--- a/pypy/goal/targetpypystandalone.py
+++ b/pypy/goal/targetpypystandalone.py
@@ -240,8 +240,9 @@
"when --shared is on (it is by default). "
"See issue #1971.")
if sys.platform == 'win32':
- config.translation.libname = '..\\..\\libs\\python27.lib'
- thisdir.join('..', '..', 'libs').ensure(dir=1)
+ libdir = thisdir.join('..', '..', 'libs')
+ libdir.ensure(dir=1)
+ config.translation.libname = str(libdir.join('python27.lib'))
if config.translation.thread:
config.objspace.usemodules.thread = True
diff --git a/rpython/translator/driver.py b/rpython/translator/driver.py
--- a/rpython/translator/driver.py
+++ b/rpython/translator/driver.py
@@ -490,10 +490,12 @@
# for pypy, the import library is renamed and moved to
# libs/python27.lib, according to the pragma in pyconfig.h
libname = self.config.translation.libname
- libname = libname or soname.new(ext='lib').basename
- libname = str(newsoname.dirpath().join(libname))
- shutil.copyfile(str(soname.new(ext='lib')), libname)
- self.log.info("copied: %s" % (libname,))
+ oldlibname = soname.new(ext='lib')
+ if not libname:
+ libname = oldlibname.basename
+ libname = str(newsoname.dirpath().join(libname))
+ shutil.copyfile(str(oldlibname), libname)
+ self.log.info("copied: %s to %s" % (oldlibname, libname,))
# the pdb file goes in the same place as pypy(w).exe
ext_to_copy = ['pdb',]
for ext in ext_to_copy:
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit