Issue 27101: Compilation of python (modules) for foreign target platform problem. (original) (raw)

Created on 2016-05-24 05:14 by complement, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
0001-Compilation-modules-for-foreign-target-platform.patch complement,2016-05-25 04:08 [PATCH 1/2] Compilation modules for foreign target platform
0002-Compilation-ssl-module-for-foreign-target-platform.patch complement,2016-05-25 04:09 [PATCH 2/2] Compilation ssl module for foreign target platform
0001-Compilation-modules-for-foreign-target-platform.patch complement,2016-05-25 04:12 [PATCH 1/2] Compilation modules for foreign target platform
0002-Compilation-ssl-module-for-foreign-target-platform.patch complement,2016-05-25 04:13 [PATCH 2/2] Compilation ssl module for foreign target platform
Messages (10)
msg266225 - (view) Author: Petr Ovtchenkov (complement) Date: 2016-05-24 05:14
Compilation of python for foreign target platform problem. Host arch is x86_64, target arch is arm (arm32). Configuration is (target arch part): (cd build-python && \ DESTDIR=${SYSROOT} \ PKG_CONFIG=true \ LIBFFI_INCLUDEDIR= \ PATH=${CURDIR}/host-python-home/bin:$$PATH \ PYTHONHOME=${CURDIR}/host-python-home/lib \ PYTHONPATH=${CURDIR}/host-python-home/lib/python3.5 \ ../cpython/configure \ --host=${TARGET_CROSS} \ --build=${BUILD_M_ARCH}-unknown-linux-gnu \ --prefix=/usr \ --sysconfdir=/etc \ --localstatedir=/var \ --enable-shared \ --disable-ipv6 \ --with-system-ffi \ --with-system-expat \ --without-ensurepip \ --cache-file=config.cache\ ) sed -e 's/#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1/#undef HAVE_ATTRIBUTE_FORMAT_PARSETUPLE/' -i build-python/pyconfig.h sed -e '/^PGEN=/ s|=.*$$ =\t\t${CURDIR}/build-python-native/Parser/pgen ' -e '/^LDFLAGS=/ s
msg266298 - (view) Author: Petr Ovtchenkov (complement) Date: 2016-05-25 04:08
for 3.5 branch
msg266299 - (view) Author: Petr Ovtchenkov (complement) Date: 2016-05-25 04:09
for 3.5 branch
msg266300 - (view) Author: Petr Ovtchenkov (complement) Date: 2016-05-25 04:12
for 2.7 branch
msg266301 - (view) Author: Petr Ovtchenkov (complement) Date: 2016-05-25 04:13
for 2.7 branch
msg267345 - (view) Author: Matthias Klose (doko) * (Python committer) Date: 2016-06-04 23:28
The 0002-* patches look fine, however the 0001-* patches are wrong if you are in a Multi-Arch environment, where you can find valid headers in /usr/include. From my point of view, the set of include and header directories should be directly initialized from the compiler defaults, and not hard coded.
msg267520 - (view) Author: Petr Ovtchenkov (complement) Date: 2016-06-06 07:32
Matthias, This question is really for you: fc1903166 (doko 2012-09-21 13:52:29 +0200 422) if multiarch_path_component != '': fc1903166 (doko 2012-09-21 13:52:29 +0200 423) add_dir_to_list(self.compiler.library_dirs, fc1903166 (doko 2012-09-21 13:52:29 +0200 424) '/usr/lib/' + multiarch_path_component) fc1903166 (doko 2012-09-21 13:52:29 +0200 425) add_dir_to_list(self.compiler.include_dirs, fc1903166 (doko 2012-09-21 13:52:29 +0200 426) '/usr/include/' + multiarch_path_component) fc1903166 (doko 2012-09-21 13:52:29 +0200 427) return
msg267533 - (view) Author: Matthias Klose (doko) * (Python committer) Date: 2016-06-06 14:55
sorry, I don't understand your last comment.
msg267538 - (view) Author: Petr Ovtchenkov (complement) Date: 2016-06-06 16:09
This mean that code for search in /usr/include/... in multiarch environment was added by you in commit fc1903166 2012-09-21 13:52:29 +0200, so in my suggestion I just don't change behaviour of you code. As for my opinion, any additions of -I/usr/include/... are wrong: compiler either see it without such -I... or shouldn't see it at all (as for cross), or require hint from builder (something like CURSES_CFLAGS=-I/home/bluser/new_curses/include).
msg412092 - (view) Author: Irit Katriel (iritkatriel) * (Python committer) Date: 2022-01-29 18:37
2.7 and 3.5 are no longer maintained. Please create a new issue if you are still having this problem with a current version (>= 3.9).
History
Date User Action Args
2022-04-11 14:58:31 admin set github: 71288
2022-01-29 18:37:52 iritkatriel set status: open -> closednosy: + iritkatrielmessages: + resolution: out of datestage: resolved
2016-06-06 16:09:37 complement set messages: +
2016-06-06 14:55:56 doko set messages: +
2016-06-06 07:32:30 complement set messages: +
2016-06-04 23:28:23 doko set messages: +
2016-05-28 15:31:22 ned.deily set nosy: + doko
2016-05-25 04:13:33 complement set files: + 0002-Compilation-ssl-module-for-foreign-target-platform.patchmessages: +
2016-05-25 04:12:48 complement set files: + 0001-Compilation-modules-for-foreign-target-platform.patchmessages: + versions: + Python 2.7
2016-05-25 04:09:12 complement set files: + 0002-Compilation-ssl-module-for-foreign-target-platform.patchmessages: +
2016-05-25 04:08:04 complement set files: + 0001-Compilation-modules-for-foreign-target-platform.patchmessages: +
2016-05-25 04:05:55 complement set files: - cpython.patch
2016-05-24 05:14:47 complement create