Package: libpython2.7-minimal Version: 2.7.12-7 Tags: patch User: [email protected] Usertags: rebootstrap Control: affects -1 + src:protobuf
protobuf fails to cross build from source, because building the python2 extension fails. It uses the recorded CC (cross compiler) for compiling C++ files (which apparently works) and then fails linking the extension with "c++". That value comes from _sysconfigdata_nd.py key CXX. It should really contain a cross compiler. The attached patch fixes the problem by passing the right CXX to ./configure as already happens for python3.5 where this problem is not present. Please consider applying it. Helmut
diff -u python2.7-2.7.12/debian/changelog python2.7-2.7.12/debian/changelog --- python2.7-2.7.12/debian/changelog +++ python2.7-2.7.12/debian/changelog @@ -1,3 +1,11 @@ +python2.7 (2.7.12-7.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix wrong CXX in _sysconfigdata_nd.py: Pass CXX to configure. (Closes: + #-1) + + -- Helmut Grohne <[email protected]> Wed, 30 Nov 2016 10:51:39 +0100 + python2.7 (2.7.12-7) unstable; urgency=medium * Update to 20161121 from the 2.7 branch. diff -u python2.7-2.7.12/debian/rules python2.7-2.7.12/debian/rules --- python2.7-2.7.12/debian/rules +++ python2.7-2.7.12/debian/rules @@ -340,7 +340,7 @@ rm -rf $(buildd_shared) mkdir -p $(buildd_shared) cd $(buildd_shared) && \ - CC="$(CC)" AR="$(AR)" RANLIB="$(RANLIB)" \ + CC="$(CC)" CXX="$(CXX)" AR="$(AR)" RANLIB="$(RANLIB)" \ CFLAGS="$(OPT_CFLAGS)" LDFLAGS="$(DPKG_LDFLAGS)" \ $(config_site) \ ../configure \ @@ -355,7 +355,7 @@ rm -rf $(buildd_static) mkdir -p $(buildd_static) cd $(buildd_static) && \ - CC="$(CC)" AR="$(AR)" RANLIB="$(RANLIB)" \ + CC="$(CC)" CXX="$(CXX)" AR="$(AR)" RANLIB="$(RANLIB)" \ CFLAGS="$(OPT_CFLAGS)" LDFLAGS="$(DPKG_LDFLAGS)" \ $(config_site) \ ../configure \ @@ -369,7 +369,7 @@ rm -rf $(buildd_debug) mkdir -p $(buildd_debug) cd $(buildd_debug) && \ - CC="$(CC)" AR="$(AR)" RANLIB="$(RANLIB)" \ + CC="$(CC)" CXX="$(CXX)" AR="$(AR)" RANLIB="$(RANLIB)" \ CFLAGS="$(DEBUG_CFLAGS)" LDFLAGS="$(DPKG_LDFLAGS)" \ $(config_site) \ ../configure \ @@ -384,7 +384,7 @@ rm -rf $(buildd_shdebug) mkdir -p $(buildd_shdebug) cd $(buildd_shdebug) && \ - CC="$(CC)" AR="$(AR)" RANLIB="$(RANLIB)" \ + CC="$(CC)" CXX="$(CXX)" AR="$(AR)" RANLIB="$(RANLIB)" \ CFLAGS="$(DEBUG_CFLAGS)" LDFLAGS="$(DPKG_LDFLAGS)" \ $(config_site) \ ../configure \

