-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix libffi recipe, and build + runtime linker errors when compiling o…
…n WSL (#1744) * Fix libffi linker errors when compiling on WSL Optional use of lld (LLVM's linker), and include a python37 bugfix. https://clang.llvm.org/docs/Toolchain.html https://lld.llvm.org/ https://bz-attachments.freebsd.org/attachment.cgi?id=200526 * Remove lld unsupported fix-cortex-a8 from LDFLAGS android/ndk#313 android/ndk#766 https://developer.android.com/ndk/guides/standalone_toolchain * Fix libffi recipe, runtime libffi linker errors. Libtool didnt like the space after --sysroot, replaced with = * CRAs - Check for lld before using it. Changed hardcoded cpu count to cpu_count(). Added comment to python patch. Made remove-fix-cortex-a8.patch conditional on lld. Moved LDFLAGS change to get_recipe_env() so its not libffi specific within python.py.
- Loading branch information
1 parent
6c4fcd0
commit f16a665
Showing
5 changed files
with
30 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
pythonforandroid/recipes/python3/patches/remove-fix-cortex-a8.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
This patch removes --fix-cortex-a8 from the linker flags in order to support linking | ||
with lld, as lld does not support this flag (https://github.com/android-ndk/ndk/issues/766). | ||
diff --git a/configure b/configure | ||
--- a/configure | ||
+++ b/configure | ||
@@ -5671,7 +5671,7 @@ $as_echo_n "checking for the Android arm ABI... " >&6; } | ||
$as_echo "$_arm_arch" >&6; } | ||
if test "$_arm_arch" = 7; then | ||
BASECFLAGS="${BASECFLAGS} -mfloat-abi=softfp -mfpu=vfpv3-d16" | ||
- LDFLAGS="${LDFLAGS} -march=armv7-a -Wl,--fix-cortex-a8" | ||
+ LDFLAGS="${LDFLAGS} -march=armv7-a" | ||
fi | ||
else | ||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: not Android" >&5 |