Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:Ledest:erlang:23
erlang
1035-Update-Android-cross-compilation.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 1035-Update-Android-cross-compilation.patch of Package erlang
From de832561d922b290652070b7db0d97ddad5a8272 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20de=20Bretagne?= <jerome.debretagne@gmail.com> Date: Fri, 19 Aug 2022 20:53:28 +0200 Subject: [PATCH 1/3] Update Android cross compilation --- xcomp/erl-xcomp-arm-android.conf | 22 ++++++++++++++++------ xcomp/erl-xcomp-arm64-android.conf | 22 ++++++++++++++++------ xcomp/erl-xcomp-x86_64-android.conf | 12 ++++++++---- 3 files changed, 40 insertions(+), 16 deletions(-) diff --git a/xcomp/erl-xcomp-arm-android.conf b/xcomp/erl-xcomp-arm-android.conf index f1164adf3c..ece87e66d8 100644 --- a/xcomp/erl-xcomp-arm-android.conf +++ b/xcomp/erl-xcomp-arm-android.conf @@ -2,7 +2,7 @@ ## ## %CopyrightBegin% ## -## Copyright Ericsson AB 2009-2021. All Rights Reserved. +## Copyright Ericsson AB 2009-2022. All Rights Reserved. ## ## Licensed under the Apache License, Version 2.0 (the "License"); ## you may not use this file except in compliance with the License. @@ -72,9 +72,13 @@ erl_xcomp_configure_flags="--without-termcap --without-wx \ # Previously with older Android NDK versions before NDK r14, each Android # API level had a different set of headers, each in its own directory. #NDK_SYSROOT=$NDK_ROOT/platforms/$NDK_PLAT/arch-arm -# Starting with Android NDK r14, a single set of headers (called Unified Headers) -# is provided in one location for every Android API level. -NDK_SYSROOT=$NDK_ROOT/sysroot +# Starting with Android NDK r14, a single set of headers (called Unified +# Headers) is provided in one location for every Android API level. +#NDK_SYSROOT=$NDK_ROOT/sysroot +# Starting with Android NDK r19, the actual sysroot path is not needed +# anymore as the NDK toolchain handles it implicitly. +# For reference: https://github.com/android/ndk/issues/1407 +#NDK_SYSROOT=$NDK_ROOT/toolchains/llvm/prebuilt/linux-x86_64/sysroot ## If the cross compilation tools are prefixed by `<HOST>-' you probably do ## not need to set these variables (where `<HOST>' is what has been passed as @@ -187,7 +191,13 @@ LDFLAGS="-march=armv7-a -mfloat-abi=softfp -mthumb" # skipped if the system root has not been set. The system root might be # needed for other things too. If this is the case and the system root # has not been set, `configure' will fail and request you to set it. -erl_xcomp_sysroot="$NDK_SYSROOT" +# +# Previously for older Android NDK versions before NDK r19. +#erl_xcomp_sysroot="$NDK_SYSROOT" +# Starting with Android NDK r19, this path does not matter anymore +# as the NDK toolchain handles the sysroot directory implicitly. +# Set a value anyway to enable all applications as described above. +erl_xcomp_sysroot=/sysroot/path/handled/by/the/Android/NDK # * `erl_xcomp_isysroot' - The absolute path to the system root for includes diff --git a/xcomp/erl-xcomp-arm64-android.conf b/xcomp/erl-xcomp-arm64-android.conf index 0308952add..62ba76a5cf 100644 --- a/xcomp/erl-xcomp-arm64-android.conf +++ b/xcomp/erl-xcomp-arm64-android.conf @@ -2,7 +2,7 @@ ## ## %CopyrightBegin% ## -## Copyright Ericsson AB 2019-2021. All Rights Reserved. +## Copyright Ericsson AB 2019-2022. All Rights Reserved. ## ## Licensed under the Apache License, Version 2.0 (the "License"); ## you may not use this file except in compliance with the License. @@ -62,7 +62,7 @@ erl_xcomp_host=aarch64-linux-android # `configure' script. # Set --enable-builtin-zlib to avoid a inflateGetDictionary missing symbol erl_xcomp_configure_flags="--disable-hipe --without-termcap --without-wx \ - --enable-builtin-zlib" + --enable-builtin-zlib" ## -- Cross Compiler and Other Tools ------------------------------------------- @@ -72,9 +72,13 @@ erl_xcomp_configure_flags="--without-termcap --without-wx \ # Previously with older Android NDK versions before NDK r14, each Android # API level had a different set of headers, each in its own directory. #NDK_SYSROOT=$NDK_ROOT/platforms/$NDK_PLAT/arch-arm -# Starting with Android NDK r14, a single set of headers (called Unified Headers) -# is provided in one location for every Android API level. -NDK_SYSROOT=$NDK_ROOT/sysroot +# Starting with Android NDK r14, a single set of headers (called Unified +# Headers) is provided in one location for every Android API level. +#NDK_SYSROOT=$NDK_ROOT/sysroot +# Starting with Android NDK r19, the actual sysroot path is not needed +# anymore as the NDK toolchain handles it implicitly. +# For reference: https://github.com/android/ndk/issues/1407 +#NDK_SYSROOT=$NDK_ROOT/toolchains/llvm/prebuilt/linux-x86_64/sysroot ## If the cross compilation tools are prefixed by `<HOST>-' you probably do ## not need to set these variables (where `<HOST>' is what has been passed as @@ -177,7 +181,13 @@ LD="aarch64-linux-android-ld" # skipped if the system root has not been set. The system root might be # needed for other things too. If this is the case and the system root # has not been set, `configure' will fail and request you to set it. -erl_xcomp_sysroot="$NDK_SYSROOT" +# +# Previously for older Android NDK versions before NDK r19. +#erl_xcomp_sysroot="$NDK_SYSROOT" +# Starting with Android NDK r19, this path does not matter anymore +# as the NDK toolchain handles the sysroot directory implicitly. +# Set a value anyway to enable all applications as described above. +erl_xcomp_sysroot=/sysroot/path/handled/by/the/Android/NDK # * `erl_xcomp_isysroot' - The absolute path to the system root for includes diff --git a/xcomp/erl-xcomp-x86_64-android.conf b/xcomp/erl-xcomp-x86_64-android.conf index abbf6e1068..26f8765b2e 100644 --- a/xcomp/erl-xcomp-x86_64-android.conf +++ b/xcomp/erl-xcomp-x86_64-android.conf @@ -2,7 +2,7 @@ ## ## %CopyrightBegin% ## -## Copyright Ericsson AB 2021. All Rights Reserved. +## Copyright Ericsson AB 2021-2022. All Rights Reserved. ## ## Licensed under the Apache License, Version 2.0 (the "License"); ## you may not use this file except in compliance with the License. @@ -60,8 +60,8 @@ erl_xcomp_host=x86_64-linux-android # * `erl_xcomp_configure_flags' - Extra configure flags to pass to the # `configure' script. -erl_xcomp_configure_flags="--disable-hipe --without-termcap --without-wx \ - --enable-builtin-zlib" +erl_xcomp_configure_flags="--without-termcap --without-wx \ + --enable-builtin-zlib" ## -- Cross Compiler and Other Tools ------------------------------------------- @@ -155,7 +155,11 @@ LD=x86_64-linux-android-ld.gold # skipped if the system root has not been set. The system root might be # needed for other things too. If this is the case and the system root # has not been set, `configure' will fail and request you to set it. -erl_xcomp_sysroot="$NDK_ROOT/sys_root" +# +# Starting with Android NDK r19, this path does not matter anymore +# as the NDK toolchain handles the sysroot directory implicitly. +# Set a value anyway to enable all applications as described above. +erl_xcomp_sysroot=/sysroot/path/handled/by/the/Android/NDK # * `erl_xcomp_isysroot' - The absolute path to the system root for includes # of the cross compilation environment. If not set, this value defaults -- 2.35.3
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor