[pypy-svn] r59258 - pypy/branch/cbuild-refactor/pypy/translator/platform

fijal at codespeak.net fijal at codespeak.net
Mon Oct 20 13:07:20 CEST 2008


Author: fijal
Date: Mon Oct 20 13:07:19 2008
New Revision: 59258

Modified:
   pypy/branch/cbuild-refactor/pypy/translator/platform/posix.py
Log:
move _compile_o_files to base class


Modified: pypy/branch/cbuild-refactor/pypy/translator/platform/posix.py
==============================================================================
--- pypy/branch/cbuild-refactor/pypy/translator/platform/posix.py	(original)
+++ pypy/branch/cbuild-refactor/pypy/translator/platform/posix.py	Mon Oct 20 13:07:19 2008
@@ -24,7 +24,16 @@
             args = self._args_for_shared(args)
         self._execute_c_compiler(cc, args, exe_name)
         return exe_name
-        
+
+    def _compile_o_files(self, cfiles, eci, standalone=True):
+        cfiles = [py.path.local(f) for f in cfiles]
+        cfiles += [py.path.local(f) for f in eci.separate_module_files]
+        compile_args = self._compile_args_from_eci(eci, standalone)
+        ofiles = []
+        for cfile in cfiles:
+            ofiles.append(self._compile_c_file(self.cc, cfile, compile_args))
+        return ofiles
+
     def gen_makefile(self, cfiles, eci, exe_name=None, path=None):
         cfiles = [py.path.local(f) for f in cfiles]
         cfiles += [py.path.local(f) for f in eci.separate_module_files]



More information about the Pypy-commit mailing list