[pypy-commit] pypy osx-shared: Move rpath_flags from Posix platform instance to the class.

larstiq noreply at buildbot.pypy.org
Wed Dec 31 07:59:54 CET 2014


Author: Wouter van Heyst <wouter.pypy at richtlijn.be>
Branch: osx-shared
Changeset: r75183:47c7b39c1da6
Date: 2014-12-31 08:56 +0200
http://bitbucket.org/pypy/pypy/changeset/47c7b39c1da6/

Log:	Move rpath_flags from Posix platform instance to the class.

diff --git a/rpython/translator/platform/darwin.py b/rpython/translator/platform/darwin.py
--- a/rpython/translator/platform/darwin.py
+++ b/rpython/translator/platform/darwin.py
@@ -10,10 +10,7 @@
 
     so_ext = 'dylib'
     DEFAULT_CC = 'clang'
-
-    def __init__(self, cc=None):
-        super(Darwin, self).__init__(cc)
-        self.rpath_flags = ['-Wl,-rpath', '-Wl, at executable_path']
+    rpath_flags = ['-Wl,-rpath', '-Wl, at executable_path']
 
     def _args_for_shared(self, args):
         return (list(self.shared_only)
diff --git a/rpython/translator/platform/posix.py b/rpython/translator/platform/posix.py
--- a/rpython/translator/platform/posix.py
+++ b/rpython/translator/platform/posix.py
@@ -14,10 +14,10 @@
     relevant_environ = ('CPATH', 'LIBRARY_PATH', 'C_INCLUDE_PATH')
 
     DEFAULT_CC = 'gcc'
+    rpath_flags = ['-Wl,-rpath=\'$$ORIGIN/\'']
 
     def __init__(self, cc=None):
         self.cc = cc or os.environ.get('CC', self.DEFAULT_CC)
-        self.rpath_flags = ['-Wl,-rpath=\'$$ORIGIN/\'']
 
     def _libs(self, libraries):
         return ['-l%s' % lib for lib in libraries]


More information about the pypy-commit mailing list