--- a/targets/Linux/__init__.py Wed Nov 16 17:12:16 2011 +0100
+++ b/targets/Linux/__init__.py Wed Nov 16 17:47:13 2011 +0100
@@ -2,5 +2,7 @@
class Linux_target(toolchain_gcc):
extension = ".so"
+ def getBuilderCFLAGS(self):
+ return toolchain_gcc.getBuilderCFLAGS(self) + ["-fPIC"]
def getBuilderLDFLAGS(self):
return toolchain_gcc.getBuilderLDFLAGS(self) + ["-shared", "-lrt"]
--- a/targets/Xenomai/__init__.py Wed Nov 16 17:12:16 2011 +0100
+++ b/targets/Xenomai/__init__.py Wed Nov 16 17:47:13 2011 +0100
@@ -21,5 +21,5 @@
def getBuilderCFLAGS(self):
xeno_cflags = self.getXenoConfig("cflags")
- return toolchain_gcc.getBuilderCFLAGS(self) + xeno_cflags
+ return toolchain_gcc.getBuilderCFLAGS(self) + xeno_cflags + ["-fPIC"]