[master] Update dependencies from dotnet/arcade (#6724)
* Update dependencies from https://github.com/dotnet/arcade build 20200306.4 - Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20156.4 * Update dependencies from https://github.com/dotnet/arcade build 20200307.1 - Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20157.1 Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
This commit is contained in:
parent
79a8c80e92
commit
ac9888bc16
6 changed files with 54 additions and 134 deletions
|
@ -100,9 +100,9 @@
|
|||
</Dependency>
|
||||
</ProductDependencies>
|
||||
<ToolsetDependencies>
|
||||
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.20155.4">
|
||||
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.20157.1">
|
||||
<Uri>https://github.com/dotnet/arcade</Uri>
|
||||
<Sha>08eea2b992d991297fc23de413bddfb9b3db5082</Sha>
|
||||
<Sha>ca67e6af5b3c6d94755f0912c5365bea44130b12</Sha>
|
||||
</Dependency>
|
||||
</ToolsetDependencies>
|
||||
</Dependencies>
|
||||
|
|
|
@ -1,41 +0,0 @@
|
|||
set(CROSS_NDK_TOOLCHAIN $ENV{ROOTFS_DIR}/../)
|
||||
set(CROSS_ROOTFS ${CROSS_NDK_TOOLCHAIN}/sysroot)
|
||||
set(CLR_CMAKE_PLATFORM_ANDROID "Android")
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR arm)
|
||||
|
||||
## Specify the toolchain
|
||||
set(TOOLCHAIN "arm-linux-androideabi")
|
||||
set(CMAKE_PREFIX_PATH ${CROSS_NDK_TOOLCHAIN})
|
||||
set(TOOLCHAIN_PREFIX ${TOOLCHAIN}-)
|
||||
|
||||
find_program(CMAKE_C_COMPILER ${TOOLCHAIN_PREFIX}clang)
|
||||
find_program(CMAKE_CXX_COMPILER ${TOOLCHAIN_PREFIX}clang++)
|
||||
find_program(CMAKE_ASM_COMPILER ${TOOLCHAIN_PREFIX}clang)
|
||||
find_program(CMAKE_AR ${TOOLCHAIN_PREFIX}ar)
|
||||
find_program(CMAKE_LD ${TOOLCHAIN_PREFIX}ar)
|
||||
find_program(CMAKE_OBJCOPY ${TOOLCHAIN_PREFIX}objcopy)
|
||||
find_program(CMAKE_OBJDUMP ${TOOLCHAIN_PREFIX}objdump)
|
||||
|
||||
add_compile_options(--sysroot=${CROSS_ROOTFS})
|
||||
add_compile_options(-fPIE)
|
||||
add_compile_options(-mfloat-abi=soft)
|
||||
include_directories(SYSTEM ${CROSS_NDK_TOOLCHAIN}/include/c++/4.9.x/)
|
||||
include_directories(SYSTEM ${CROSS_NDK_TOOLCHAIN}/include/c++/4.9.x/arm-linux-androideabi/)
|
||||
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} -B ${CROSS_ROOTFS}/usr/lib/gcc/${TOOLCHAIN}")
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} -L${CROSS_ROOTFS}/lib/${TOOLCHAIN}")
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} --sysroot=${CROSS_ROOTFS}")
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} -fPIE -pie")
|
||||
|
||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${CROSS_LINK_FLAGS}" CACHE STRING "" FORCE)
|
||||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${CROSS_LINK_FLAGS}" CACHE STRING "" FORCE)
|
||||
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${CROSS_LINK_FLAGS}" CACHE STRING "" FORCE)
|
||||
|
||||
set(CMAKE_FIND_ROOT_PATH "${CROSS_ROOTFS}")
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
|
|
@ -1,42 +0,0 @@
|
|||
set(CROSS_NDK_TOOLCHAIN $ENV{ROOTFS_DIR}/../)
|
||||
set(CROSS_ROOTFS ${CROSS_NDK_TOOLCHAIN}/sysroot)
|
||||
set(CLR_CMAKE_PLATFORM_ANDROID "Android")
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR aarch64)
|
||||
|
||||
## Specify the toolchain
|
||||
set(TOOLCHAIN "aarch64-linux-android")
|
||||
set(CMAKE_PREFIX_PATH ${CROSS_NDK_TOOLCHAIN})
|
||||
set(TOOLCHAIN_PREFIX ${TOOLCHAIN}-)
|
||||
|
||||
find_program(CMAKE_C_COMPILER ${TOOLCHAIN_PREFIX}clang)
|
||||
find_program(CMAKE_CXX_COMPILER ${TOOLCHAIN_PREFIX}clang++)
|
||||
find_program(CMAKE_ASM_COMPILER ${TOOLCHAIN_PREFIX}clang)
|
||||
find_program(CMAKE_AR ${TOOLCHAIN_PREFIX}ar)
|
||||
find_program(CMAKE_LD ${TOOLCHAIN_PREFIX}ar)
|
||||
find_program(CMAKE_OBJCOPY ${TOOLCHAIN_PREFIX}objcopy)
|
||||
find_program(CMAKE_OBJDUMP ${TOOLCHAIN_PREFIX}objdump)
|
||||
|
||||
add_compile_options(--sysroot=${CROSS_ROOTFS})
|
||||
add_compile_options(-fPIE)
|
||||
|
||||
## Needed for Android or bionic specific conditionals
|
||||
add_compile_options(-D__ANDROID__)
|
||||
add_compile_options(-D__BIONIC__)
|
||||
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} -B ${CROSS_ROOTFS}/usr/lib/gcc/${TOOLCHAIN}")
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} -L${CROSS_ROOTFS}/lib/${TOOLCHAIN}")
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} --sysroot=${CROSS_ROOTFS}")
|
||||
set(CROSS_LINK_FLAGS "${CROSS_LINK_FLAGS} -fPIE -pie")
|
||||
|
||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${CROSS_LINK_FLAGS}" CACHE STRING "" FORCE)
|
||||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${CROSS_LINK_FLAGS}" CACHE STRING "" FORCE)
|
||||
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${CROSS_LINK_FLAGS}" CACHE STRING "" FORCE)
|
||||
|
||||
set(CMAKE_FIND_ROOT_PATH "${CROSS_ROOTFS}")
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
|
|
@ -1,6 +1,6 @@
|
|||
#!/usr/bin/env bash
|
||||
set -e
|
||||
__NDK_Version=r14
|
||||
__NDK_Version=r21
|
||||
|
||||
usage()
|
||||
{
|
||||
|
@ -16,11 +16,11 @@ usage()
|
|||
echo.
|
||||
echo "By default, the NDK will be downloaded into the cross/android-rootfs/android-ndk-$__NDK_Version directory. If you already have an NDK installation,"
|
||||
echo "you can set the NDK_DIR environment variable to have this script use that installation of the NDK."
|
||||
echo "By default, this script will generate a file, android_platform, in the root of the ROOTFS_DIR directory that contains the RID for the supported and tested Android build: android.21-arm64. This file is to replace '/etc/os-release', which is not available for Android."
|
||||
echo "By default, this script will generate a file, android_platform, in the root of the ROOTFS_DIR directory that contains the RID for the supported and tested Android build: android.28-arm64. This file is to replace '/etc/os-release', which is not available for Android."
|
||||
exit 1
|
||||
}
|
||||
|
||||
__ApiLevel=21 # The minimum platform for arm64 is API level 21
|
||||
__ApiLevel=28 # The minimum platform for arm64 is API level 21 but the minimum version that support glob(3) is 28. See $ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/include/glob.h
|
||||
__BuildArch=arm64
|
||||
__AndroidArch=aarch64
|
||||
__AndroidToolchain=aarch64-linux-android
|
||||
|
@ -54,12 +54,11 @@ done
|
|||
|
||||
# Obtain the location of the bash script to figure out where the root of the repo is.
|
||||
__CrossDir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
__Android_Cross_Dir="$(cd "$__CrossDir/../../../.tools/android-rootfs" && pwd)"
|
||||
|
||||
__Android_Cross_Dir="$__CrossDir/android-rootfs"
|
||||
__NDK_Dir="$__Android_Cross_Dir/android-ndk-$__NDK_Version"
|
||||
__libunwind_Dir="$__Android_Cross_Dir/libunwind"
|
||||
__lldb_Dir="$__Android_Cross_Dir/lldb"
|
||||
__ToolchainDir="$__Android_Cross_Dir/toolchain/$__BuildArch"
|
||||
__ToolchainDir="$__Android_Cross_Dir/android-ndk-$__NDK_Version"
|
||||
|
||||
if [[ -n "$TOOLCHAIN_DIR" ]]; then
|
||||
__ToolchainDir=$TOOLCHAIN_DIR
|
||||
|
@ -89,49 +88,33 @@ if [ ! -d $__lldb_Dir ]; then
|
|||
unzip -q $__Android_Cross_Dir/lldb-2.3.3614996-linux-x86_64.zip -d $__lldb_Dir
|
||||
fi
|
||||
|
||||
# Create the RootFS for both arm64 as well as aarch
|
||||
rm -rf $__Android_Cross_Dir/toolchain
|
||||
|
||||
echo Generating the $__BuildArch toolchain
|
||||
$__NDK_Dir/build/tools/make_standalone_toolchain.py --arch $__BuildArch --api $__ApiLevel --install-dir $__ToolchainDir
|
||||
|
||||
# Install the required packages into the toolchain
|
||||
# TODO: Add logic to get latest pkg version instead of specific version number
|
||||
rm -rf $__Android_Cross_Dir/deb/
|
||||
rm -rf $__Android_Cross_Dir/tmp
|
||||
|
||||
mkdir -p $__Android_Cross_Dir/deb/
|
||||
echo "Download dependencies..."
|
||||
mkdir -p $__Android_Cross_Dir/tmp/$arch/
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libicu_60.2_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libicu_60.2_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libicu-dev_60.2_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libicu-dev_60.2_$__AndroidArch.deb
|
||||
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libandroid-glob-dev_0.4_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libandroid-glob-dev_0.4_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libandroid-glob_0.4_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libandroid-glob_0.4_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libandroid-support-dev_22_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libandroid-support-dev_22_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libandroid-support_22_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libandroid-support_22_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/liblzma-dev_5.2.3_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/liblzma-dev_5.2.3_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/liblzma_5.2.3_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/liblzma_5.2.3_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libunwind-dev_1.2.20170304_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libunwind-dev_1.2.20170304_$__AndroidArch.deb
|
||||
wget -nv -nc http://termux.net/dists/stable/main/binary-$__AndroidArch/libunwind_1.2.20170304_$__AndroidArch.deb -O $__Android_Cross_Dir/deb/libunwind_1.2.20170304_$__AndroidArch.deb
|
||||
# combined dependencies for coreclr, installer and libraries
|
||||
__AndroidPackages="libicu"
|
||||
__AndroidPackages+=" libandroid-glob"
|
||||
__AndroidPackages+=" liblzma"
|
||||
__AndroidPackages+=" krb5"
|
||||
__AndroidPackages+=" openssl"
|
||||
|
||||
echo Unpacking Termux packages
|
||||
dpkg -x $__Android_Cross_Dir/deb/libicu_60.2_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/libicu-dev_60.2_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/libandroid-glob-dev_0.4_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/libandroid-glob_0.4_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/libandroid-support-dev_22_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/libandroid-support_22_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/liblzma-dev_5.2.3_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/liblzma_5.2.3_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/libunwind-dev_1.2.20170304_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
dpkg -x $__Android_Cross_Dir/deb/libunwind_1.2.20170304_$__AndroidArch.deb $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
for path in $(wget -qO- http://termux.net/dists/stable/main/binary-$__AndroidArch/Packages |\
|
||||
grep -A15 "Package: \(${__AndroidPackages// /\\|}\)" | grep -v "static\|tool" | grep Filename); do
|
||||
|
||||
if [[ "$path" != "Filename:" ]]; then
|
||||
echo "Working on: $path"
|
||||
wget -qO- http://termux.net/$path | dpkg -x - $__Android_Cross_Dir/tmp/$__AndroidArch/
|
||||
fi
|
||||
done
|
||||
|
||||
cp -R $__Android_Cross_Dir/tmp/$__AndroidArch/data/data/com.termux/files/usr/* $__ToolchainDir/sysroot/usr/
|
||||
|
||||
# Generate platform file for build.sh script to assign to __DistroRid
|
||||
echo "Generating platform file..."
|
||||
echo "RID=android.${__ApiLevel}-${__BuildArch}" > $__ToolchainDir/sysroot/android_platform
|
||||
|
||||
echo "RID=android.21-arm64" > $__ToolchainDir/sysroot/android_platform
|
||||
echo Now run:
|
||||
echo CONFIG_DIR=\`realpath cross/android/$__BuildArch\` ROOTFS_DIR=\`realpath $__ToolchainDir/sysroot\` ./build.sh cross $__BuildArch skipgenerateversion skipnuget cmakeargs -DENABLE_LLDBPLUGIN=0
|
||||
|
||||
echo "Now to build coreclr, libraries and installers; run:"
|
||||
echo ROOTFS_DIR=\$\(realpath $__ToolchainDir/sysroot\) ./build.sh --cross --arch $__BuildArch \
|
||||
--subsetCategory coreclr \
|
||||
--subsetCategory libraries \
|
||||
--subsetCategory installer
|
||||
|
|
|
@ -43,10 +43,30 @@ if(TARGET_ARCH_NAME STREQUAL "armel")
|
|||
endif()
|
||||
endif()
|
||||
|
||||
set(CMAKE_SYSROOT "${CROSS_ROOTFS}")
|
||||
set(CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN "${CROSS_ROOTFS}/usr")
|
||||
set(CMAKE_CXX_COMPILER_EXTERNAL_TOOLCHAIN "${CROSS_ROOTFS}/usr")
|
||||
set(CMAKE_ASM_COMPILER_EXTERNAL_TOOLCHAIN "${CROSS_ROOTFS}/usr")
|
||||
if("$ENV{__DistroRid}" MATCHES "android.*")
|
||||
if(TARGET_ARCH_NAME STREQUAL "arm")
|
||||
set(ANDROID_ABI armeabi-v7a)
|
||||
elseif(TARGET_ARCH_NAME STREQUAL "arm64")
|
||||
set(ANDROID_ABI arm64-v8a)
|
||||
endif()
|
||||
|
||||
# extract platform number required by the NDK's toolchain
|
||||
string(REGEX REPLACE ".*\\.([0-9]+)-.*" "\\1" ANDROID_PLATFORM "$ENV{__DistroRid}")
|
||||
|
||||
set(ANDROID_TOOLCHAIN clang)
|
||||
set(FEATURE_EVENT_TRACE 0) # disable event trace as there is no lttng-ust package in termux repository
|
||||
set(CMAKE_SYSTEM_LIBRARY_PATH "${CROSS_ROOTFS}/usr/lib")
|
||||
set(CMAKE_SYSTEM_INCLUDE_PATH "${CROSS_ROOTFS}/usr/include")
|
||||
|
||||
# include official NDK toolchain script
|
||||
include(${CROSS_ROOTFS}/../build/cmake/android.toolchain.cmake)
|
||||
else()
|
||||
set(CMAKE_SYSROOT "${CROSS_ROOTFS}")
|
||||
|
||||
set(CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN "${CROSS_ROOTFS}/usr")
|
||||
set(CMAKE_CXX_COMPILER_EXTERNAL_TOOLCHAIN "${CROSS_ROOTFS}/usr")
|
||||
set(CMAKE_ASM_COMPILER_EXTERNAL_TOOLCHAIN "${CROSS_ROOTFS}/usr")
|
||||
endif()
|
||||
|
||||
# Specify link flags
|
||||
|
||||
|
@ -63,7 +83,7 @@ endif()
|
|||
|
||||
# Specify compile options
|
||||
|
||||
if(TARGET_ARCH_NAME MATCHES "^(arm|armel|arm64)$")
|
||||
if(TARGET_ARCH_NAME MATCHES "^(arm|armel|arm64)$" AND NOT "$ENV{__DistroRid}" MATCHES "android.*")
|
||||
set(CMAKE_C_COMPILER_TARGET ${TOOLCHAIN})
|
||||
set(CMAKE_CXX_COMPILER_TARGET ${TOOLCHAIN})
|
||||
set(CMAKE_ASM_COMPILER_TARGET ${TOOLCHAIN})
|
||||
|
|
|
@ -8,6 +8,6 @@
|
|||
}
|
||||
},
|
||||
"msbuild-sdks": {
|
||||
"Microsoft.DotNet.Arcade.Sdk": "5.0.0-beta.20155.4"
|
||||
"Microsoft.DotNet.Arcade.Sdk": "5.0.0-beta.20157.1"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue