[Debichem-devel] Bug#865365: p4vasp: use -fPIC to fix FTBFS on s390x

Adrian Bunk bunk at debian.org
Tue Jun 20 17:27:20 UTC 2017


Source: p4vasp
Version: 0.3.29+dfsg-3
Severity: important
Tags: patch

The attached patch uses -fPIC to fix the FTBFS on s390x.
-------------- next part --------------
Description: Build with -fPIC instead of -fpic
 It doesn't make a difference on x86, but is required for
 linking the library on s390x and sparc64.
Author: Adrian Bunk <bunk at debian.org>

--- p4vasp-0.3.29+dfsg.orig/odpdom/Makefile
+++ p4vasp-0.3.29+dfsg/odpdom/Makefile
@@ -10,7 +10,7 @@ FLAGS   = -DPY_DOMEXC_MODULE="\"xml.dom.
 #	  -DNO_THROW
 
 PYINCLUDE=`python -c "import sys;import os.path;print os.path.join(sys.prefix,\"include\",\"python\"+sys.version[:3])"`
-CFLAGS  += -fpic -g $(CPPFLAGS) $(FLAGS) -I$(PYINCLUDE)  -Iinclude
+CFLAGS  += -fPIC -g $(CPPFLAGS) $(FLAGS) -I$(PYINCLUDE)  -Iinclude
 
 SWIGFLAGS = -python -c++ $(FLAGS)
 
--- p4vasp-0.3.29+dfsg.orig/src/Configuration.mk
+++ p4vasp-0.3.29+dfsg/src/Configuration.mk
@@ -1,6 +1,6 @@
 LIBS=  -L../odpdom -lODP $(shell fltk-config --use-gl --ldflags) -lGLU -lGL -lm -lpthread
 CFLAGS?= -g -00 -Wall
-CFLAGS+= -fpic $(CPPFLAGS) $(FLAGS) $(shell fltk-config --cxxflags) -I$(PYINCLUDE) \
+CFLAGS+= -fPIC $(CPPFLAGS) $(FLAGS) $(shell fltk-config --cxxflags) -I$(PYINCLUDE) \
         -Iinclude -I../odpdom/include
 PYINCLUDE=`python -c "import sys;import os.path;print os.path.join(sys.prefix,\"include\",\"python\"+sys.version[:3])"`
 LDFLAGS+= -shared -L.


More information about the Debichem-devel mailing list