Author: David Schneider <[email protected]>
Branch: arm-backend-2
Changeset: r53760:29963b68f806
Date: 2012-03-17 15:32 +0000
http://bitbucket.org/pypy/pypy/changeset/29963b68f806/
Log: set the -fPIC compiler flag when running on linux for ARM
diff --git a/pypy/translator/platform/linux.py
b/pypy/translator/platform/linux.py
--- a/pypy/translator/platform/linux.py
+++ b/pypy/translator/platform/linux.py
@@ -1,6 +1,7 @@
"""Support for Linux."""
import os
+import platform
import sys
from pypy.translator.platform.posix import BasePosix
@@ -41,8 +42,11 @@
class Linux(BaseLinux):
- shared_only = () # it seems that on 32-bit linux, compiling with -fPIC
- # gives assembler that asmgcc is not happy about.
+ if platform.machine().startswith('arm'):
+ shared_only = ('-fPIC',) # ARM requires compiling with -fPIC
+ else:
+ shared_only = () # it seems that on 32-bit linux, compiling with -fPIC
+ # gives assembler that asmgcc is not happy about.
class Linux64(BaseLinux):
pass
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit