mirror of
https://github.com/google/cpu_features.git
synced 2025-04-28 07:23:37 +02:00
Update cross compilation script
This commit is contained in:
parent
5ec8408da3
commit
245c812f10
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
cmake_build/
|
61
.travis.yml
61
.travis.yml
@ -4,31 +4,72 @@ sudo: false
|
|||||||
|
|
||||||
cache:
|
cache:
|
||||||
directories:
|
directories:
|
||||||
- $HOME/qemu
|
- $HOME/archives
|
||||||
- $HOME/toolchains
|
|
||||||
|
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- os: linux
|
- os: linux
|
||||||
compiler: gcc
|
compiler: gcc
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=NATIVE
|
||||||
|
TARGET=native
|
||||||
- os: linux
|
- os: linux
|
||||||
compiler: clang
|
compiler: clang
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=NATIVE
|
||||||
|
TARGET=native
|
||||||
- os: osx
|
- os: osx
|
||||||
compiler: gcc
|
compiler: gcc
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=NATIVE
|
||||||
|
TARGET=native
|
||||||
- os: osx
|
- os: osx
|
||||||
compiler: clang
|
compiler: clang
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=NATIVE
|
||||||
|
TARGET=native
|
||||||
|
# Toolchains for little-endian, 64-bit ARMv8 for GNU/Linux systems
|
||||||
- os: linux
|
- os: linux
|
||||||
env:
|
env:
|
||||||
LINARO_URL=https://releases.linaro.org/components/toolchain/binaries/7.2-2017.11/arm-linux-gnueabihf/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf.tar.xz
|
TOOLCHAIN=LINARO
|
||||||
TARGET=arm-linux-gnueabihf
|
|
||||||
QEMU_ARCHES=arm
|
|
||||||
QEMU_ARCH=arm
|
|
||||||
- os: linux
|
|
||||||
env:
|
|
||||||
LINARO_URL=https://releases.linaro.org/components/toolchain/binaries/7.2-2017.11/aarch64-linux-gnu/gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu.tar.xz
|
|
||||||
TARGET=aarch64-linux-gnu
|
TARGET=aarch64-linux-gnu
|
||||||
QEMU_ARCHES=aarch64
|
|
||||||
QEMU_ARCH=aarch64
|
QEMU_ARCH=aarch64
|
||||||
|
# Toolchains for little-endian, hard-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
- os: linux
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=arm-linux-gnueabihf
|
||||||
|
QEMU_ARCH=arm
|
||||||
|
# Toolchains for little-endian, 32-bit ARMv8 for GNU/Linux systems
|
||||||
|
- os: linux
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=armv8l-linux-gnueabihf
|
||||||
|
QEMU_ARCH=arm
|
||||||
|
# Toolchains for little-endian, soft-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
- os: linux
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=arm-linux-gnueabi
|
||||||
|
QEMU_ARCH=arm
|
||||||
|
# Toolchains for big-endian, 64-bit ARMv8 for GNU/Linux systems
|
||||||
|
- os: linux
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=aarch64_be-linux-gnu
|
||||||
|
QEMU_ARCH=""
|
||||||
|
# Toolchains for big-endian, hard-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
- os: linux
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=armeb-linux-gnueabihf
|
||||||
|
QEMU_ARCH=""
|
||||||
|
# Toolchains for big-endian, soft-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
- os: linux
|
||||||
|
env:
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=armeb-linux-gnueabi
|
||||||
|
QEMU_ARCH=""
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- cmake --version
|
- cmake --version
|
||||||
|
@ -1,18 +0,0 @@
|
|||||||
SET(CMAKE_SYSTEM_NAME Linux)
|
|
||||||
SET(CMAKE_SYSTEM_VERSION 1)
|
|
||||||
|
|
||||||
# specify the cross compiler
|
|
||||||
SET(CMAKE_C_COMPILER aarch64-linux-gnu-gcc)
|
|
||||||
SET(CMAKE_CXX_COMPILER aarch64-linux-gnu-g++)
|
|
||||||
SET(CMAKE_AR aarch64-linux-gnu-ar CACHE FILEPATH "Archiver")
|
|
||||||
|
|
||||||
SET(THREADS_PTHREAD_ARG "2" CACHE STRING "Forcibly set by CMakeLists.txt." FORCE)
|
|
||||||
|
|
||||||
# where is the target environment
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH $ENV{TOOLCHAIN})
|
|
||||||
|
|
||||||
# search for programs in the build host directories
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
|
||||||
# for libraries and headers in the target directories
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
|
@ -1,18 +0,0 @@
|
|||||||
SET(CMAKE_SYSTEM_NAME Linux)
|
|
||||||
SET(CMAKE_SYSTEM_VERSION 1)
|
|
||||||
|
|
||||||
# specify the cross compiler
|
|
||||||
SET(CMAKE_C_COMPILER arm-linux-gnueabihf-gcc -mfloat-abi=hard)
|
|
||||||
SET(CMAKE_CXX_COMPILER arm-linux-gnueabihf-g++ -mfloat-abi=hard)
|
|
||||||
SET(CMAKE_AR arm-linux-gnueabihf-ar CACHE FILEPATH "Archiver")
|
|
||||||
|
|
||||||
SET(THREADS_PTHREAD_ARG "2" CACHE STRING "Forcibly set by CMakeLists.txt." FORCE)
|
|
||||||
|
|
||||||
# where is the target environment
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH $ENV{TOOLCHAIN})
|
|
||||||
|
|
||||||
# search for programs in the build host directories
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
|
||||||
# for libraries and headers in the target directories
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
|
||||||
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
|
@ -1,37 +1,59 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
set -e
|
SCRIPT_FOLDER=$(cd -P -- "$(dirname -- "$0")" && pwd -P)
|
||||||
set -x
|
PROJECT_FOLDER="${SCRIPT_FOLDER}/.."
|
||||||
|
ARCHIVE_FOLDER=~/archives
|
||||||
|
QEMU_INSTALL=${ARCHIVE_FOLDER}/qemu
|
||||||
|
DEFAULT_CMAKE_ARGS=" -DCMAKE_BUILD_TYPE=Debug -DBUILD_TESTING=ON"
|
||||||
|
|
||||||
###############################################################################
|
function extract() {
|
||||||
# Ensures qemu is compiled in $HOME/qemu.
|
case $1 in
|
||||||
# Input:
|
*.tar.bz2) tar xjf $1 ;;
|
||||||
# - QEMU_VERSION, the version of qemu to use.
|
*.tar.xz) tar xJf $1 ;;
|
||||||
# - QEMU_ARCHES, the list of architectures qemu should support.
|
*.tar.gz) tar xzf $1 ;;
|
||||||
function setup_qemu() {
|
*)
|
||||||
local VERSION=${QEMU_VERSION:=2.11.0}
|
echo "don't know how to extract '$1'..."
|
||||||
|
exit 1
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
function unpackifnotexists() {
|
||||||
|
mkdir -p ${ARCHIVE_FOLDER}
|
||||||
|
cd ${ARCHIVE_FOLDER}
|
||||||
|
local URL=$1
|
||||||
|
local DESTINATION=`pwd`/$2
|
||||||
|
if [[ ! -d "${DESTINATION}" ]] ; then
|
||||||
|
local ARCHIVE_NAME=`echo ${URL} | sed 's/.*\///'`
|
||||||
|
test -f ${ARCHIVE_NAME} || wget ${URL}
|
||||||
|
extract ${ARCHIVE_NAME}
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function installqemuifneeded() {
|
||||||
|
local VERSION=${QEMU_VERSION:=2.11.1}
|
||||||
local ARCHES=${QEMU_ARCHES:=arm aarch64 i386 x86_64 mipsel}
|
local ARCHES=${QEMU_ARCHES:=arm aarch64 i386 x86_64 mipsel}
|
||||||
local TARGETS=${QEMU_TARGETS:=$(echo $ARCHES | sed 's#$# #;s#\([^ ]*\) #\1-softmmu \1-linux-user #g')}
|
local TARGETS=${QEMU_TARGETS:=$(echo $ARCHES | sed 's#$# #;s#\([^ ]*\) #\1-linux-user #g')}
|
||||||
|
|
||||||
if echo "$VERSION $TARGETS" | cmp --silent $HOME/qemu/.build -; then
|
if echo "${VERSION} ${TARGETS}" | cmp --silent ${QEMU_INSTALL}/.build -; then
|
||||||
echo "qemu $VERSION up to date!"
|
echo "qemu ${VERSION} up to date!"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "VERSION: $VERSION"
|
echo "VERSION: ${VERSION}"
|
||||||
echo "TARGETS: $TARGETS"
|
echo "TARGETS: ${TARGETS}"
|
||||||
|
|
||||||
cd $HOME
|
rm -rf ${QEMU_INSTALL}
|
||||||
rm -rf qemu
|
|
||||||
|
|
||||||
# Checking for a tarball before downloading makes testing easier :-)
|
# Checking for a tarball before downloading makes testing easier :-)
|
||||||
test -f "qemu-$VERSION.tar.xz" || wget "http://wiki.qemu-project.org/download/qemu-$VERSION.tar.xz"
|
local QEMU_URL="http://wiki.qemu-project.org/download/qemu-${VERSION}.tar.xz"
|
||||||
tar -xJf "qemu-$VERSION.tar.xz"
|
local QEMU_FOLDER="qemu-${VERSION}"
|
||||||
cd "qemu-$VERSION"
|
unpackifnotexists ${QEMU_URL} ${QEMU_FOLDER}
|
||||||
|
cd ${QEMU_FOLDER}
|
||||||
|
|
||||||
./configure \
|
./configure \
|
||||||
--prefix="$HOME/qemu" \
|
--prefix="${QEMU_INSTALL}" \
|
||||||
--target-list="$TARGETS" \
|
--target-list="${TARGETS}" \
|
||||||
--disable-docs \
|
--disable-docs \
|
||||||
--disable-sdl \
|
--disable-sdl \
|
||||||
--disable-gtk \
|
--disable-gtk \
|
||||||
@ -44,78 +66,83 @@ function setup_qemu() {
|
|||||||
make -j4
|
make -j4
|
||||||
make install
|
make install
|
||||||
|
|
||||||
echo "$VERSION $TARGETS" > $HOME/qemu/.build
|
echo "$VERSION $TARGETS" > ${QEMU_INSTALL}/.build
|
||||||
}
|
}
|
||||||
|
|
||||||
###############################################################################
|
function assert_defined(){
|
||||||
# Ensures the linaro toolchain is available in $HOME/toolchains.
|
: ${1?Needs to be defined}
|
||||||
# Input:
|
|
||||||
# - LINARO_URL, the url of the of the x86_64 gcc tarball.
|
|
||||||
function get_linaro_toolchain_folder() {
|
|
||||||
local LINARO_URL_NO_HTTPS=${LINARO_URL#https:}
|
|
||||||
local ARCHIVE_NAME=${LINARO_URL_NO_HTTPS##/*/}
|
|
||||||
local TOOLCHAIN_NAME=${ARCHIVE_NAME%.tar.*}
|
|
||||||
local TOOLCHAIN_HOME=${HOME}/toolchains
|
|
||||||
local TOOLCHAIN_FOLDER="${TOOLCHAIN_HOME}/${TOOLCHAIN_NAME}"
|
|
||||||
if [[ ! -d "${TOOLCHAIN_FOLDER}" ]] ; then
|
|
||||||
mkdir -p "${TOOLCHAIN_HOME}"
|
|
||||||
cd "${TOOLCHAIN_HOME}"
|
|
||||||
wget ${LINARO_URL}
|
|
||||||
tar -xJf ${ARCHIVE_NAME}
|
|
||||||
rm ${ARCHIVE_NAME}
|
|
||||||
fi
|
|
||||||
echo ${TOOLCHAIN_FOLDER}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
###############################################################################
|
function integrate_cross() {
|
||||||
|
assert_defined ${GCC_URL}
|
||||||
|
assert_defined ${GCC_RELATIVE_FOLDER}
|
||||||
|
assert_defined ${SYSROOT_URL}
|
||||||
|
assert_defined ${SYSROOT_RELATIVE_FOLDER}
|
||||||
|
|
||||||
|
unpackifnotexists ${GCC_URL} ${GCC_RELATIVE_FOLDER}
|
||||||
|
unpackifnotexists ${SYSROOT_URL} ${SYSROOT_RELATIVE_FOLDER}
|
||||||
|
|
||||||
|
local CMAKE_ARGS=${DEFAULT_CMAKE_ARGS}
|
||||||
|
|
||||||
|
# Update cmake args for cross compilation.
|
||||||
|
local SYSROOT_FOLDER=${ARCHIVE_FOLDER}/${SYSROOT_RELATIVE_FOLDER}
|
||||||
|
local GCC_FOLDER=${ARCHIVE_FOLDER}/${GCC_RELATIVE_FOLDER}
|
||||||
|
CMAKE_ARGS+=" -DCMAKE_SYSROOT=${SYSROOT_FOLDER}"
|
||||||
|
CMAKE_ARGS+=" -DCMAKE_C_COMPILER=${GCC_FOLDER}/bin/${TARGET}-gcc"
|
||||||
|
CMAKE_ARGS+=" -DCMAKE_CXX_COMPILER=${GCC_FOLDER}/bin/${TARGET}-g++"
|
||||||
|
|
||||||
SCRIPT_FOLDER=$(cd -P -- "$(dirname -- "$0")" && pwd -P)
|
|
||||||
PROJECT_FOLDER="${SCRIPT_FOLDER}/.."
|
|
||||||
cd ${PROJECT_FOLDER}
|
cd ${PROJECT_FOLDER}
|
||||||
|
cmake -H. -B${BUILD_DIR} ${CMAKE_ARGS}
|
||||||
|
cmake --build ${BUILD_DIR} --target all
|
||||||
|
|
||||||
BUILD_DIR="${PROJECT_FOLDER}/cmake_build"
|
|
||||||
CMAKE_PATH="${PATH}"
|
|
||||||
CMAKE_ARGS="-H. -B${BUILD_DIR}"
|
|
||||||
CMAKE_ARGS+=" -DCMAKE_BUILD_TYPE=Debug -DBUILD_TESTING=ON"
|
|
||||||
|
|
||||||
#
|
|
||||||
# Setup toolchain if necessary.
|
|
||||||
#
|
|
||||||
if [[ -n "${LINARO_URL}" ]]; then
|
|
||||||
# Cross compilation
|
|
||||||
: "${TARGET:?Need to set TARGET non-empty}"
|
|
||||||
TOOLCHAIN=`get_linaro_toolchain_folder`
|
|
||||||
CMAKE_TOOLCHAIN_FILE=cmake/${TARGET}.cmake
|
|
||||||
if [[ ! -f ${CMAKE_TOOLCHAIN_FILE} ]]; then
|
|
||||||
echo "Missing cmake toolchain file : $CMAKE_TOOLCHAIN_FILE"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
CMAKE_ARGS+=" -DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}"
|
|
||||||
CMAKE_PATH="${TOOLCHAIN}/bin:${PATH}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Generate makefile
|
|
||||||
PATH=${CMAKE_PATH} cmake ${CMAKE_ARGS}
|
|
||||||
# Compile
|
|
||||||
PATH=${CMAKE_PATH} cmake --build ${BUILD_DIR} --target all
|
|
||||||
|
|
||||||
#
|
|
||||||
# Tests
|
|
||||||
#
|
|
||||||
if [[ -n "${QEMU_ARCH}" ]]; then
|
if [[ -n "${QEMU_ARCH}" ]]; then
|
||||||
|
installqemuifneeded
|
||||||
|
QEMU="qemu-${QEMU_ARCH} -L ${SYSROOT_FOLDER}"
|
||||||
# Run tests
|
# Run tests
|
||||||
QEMU_PATH="${HOME}/qemu/bin:${PATH}"
|
for test_binary in ${BUILD_DIR}/test/*_test; do ${QEMU} ${test_binary}; done
|
||||||
: "${QEMU_ARCH:?Need to set QEMU_ARCH non-empty}"
|
|
||||||
setup_qemu
|
|
||||||
QEMU="qemu-${QEMU_ARCH} -L ${TOOLCHAIN}/${TARGET}/libc"
|
|
||||||
for test_binary in ${BUILD_DIR}/test/*_test; do
|
|
||||||
PATH=${QEMU_PATH} ${QEMU} ${test_binary}
|
|
||||||
done
|
|
||||||
# Run demo program
|
# Run demo program
|
||||||
PATH=${QEMU_PATH} ${QEMU} ${BUILD_DIR}/list_cpu_features
|
${QEMU} ${BUILD_DIR}/list_cpu_features
|
||||||
else
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
function integrate_native() {
|
||||||
|
local CMAKE_ARGS=${DEFAULT_CMAKE_ARGS}
|
||||||
|
|
||||||
|
cd ${PROJECT_FOLDER}
|
||||||
|
cmake -H. -B${BUILD_DIR} ${CMAKE_ARGS}
|
||||||
|
cmake --build ${BUILD_DIR} --target all
|
||||||
|
|
||||||
# Run tests
|
# Run tests
|
||||||
CTEST_OUTPUT_ON_FAILURE=1 cmake --build ${BUILD_DIR} --target test
|
for test_binary in ${BUILD_DIR}/test/*_test; do ${test_binary}; done
|
||||||
# Run demo program
|
# Run demo program
|
||||||
${BUILD_DIR}/list_cpu_features
|
${BUILD_DIR}/list_cpu_features
|
||||||
fi
|
}
|
||||||
|
|
||||||
|
function expand_linaro_config() {
|
||||||
|
assert_defined ${TARGET}
|
||||||
|
local LINARO_ROOT_URL=https://releases.linaro.org/components/toolchain/binaries/7.2-2017.11
|
||||||
|
GCC_URL=${LINARO_ROOT_URL}/${TARGET}/gcc-linaro-7.2.1-2017.11-x86_64_${TARGET}.tar.xz
|
||||||
|
GCC_RELATIVE_FOLDER=gcc-linaro-7.2.1-2017.11-x86_64_${TARGET}
|
||||||
|
SYSROOT_URL=${LINARO_ROOT_URL}/${TARGET}/sysroot-glibc-linaro-2.25-2017.11-${TARGET}.tar.xz
|
||||||
|
SYSROOT_RELATIVE_FOLDER=sysroot-glibc-linaro-2.25-2017.11-${TARGET}
|
||||||
|
}
|
||||||
|
|
||||||
|
function expand_environment_and_integrate() {
|
||||||
|
assert_defined ${PROJECT_FOLDER}
|
||||||
|
assert_defined ${TARGET}
|
||||||
|
|
||||||
|
BUILD_DIR="${PROJECT_FOLDER}/cmake_build/${TARGET}"
|
||||||
|
mkdir -p ${BUILD_DIR}
|
||||||
|
|
||||||
|
case ${TOOLCHAIN} in
|
||||||
|
LINARO)
|
||||||
|
expand_linaro_config
|
||||||
|
integrate_cross
|
||||||
|
;;
|
||||||
|
NATIVE)
|
||||||
|
integrate_native
|
||||||
|
;;
|
||||||
|
*) echo "Unknown toolchain '${TOOLCHAIN}'..."
|
||||||
|
exit 1
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
72
scripts/test_integration.sh
Executable file
72
scripts/test_integration.sh
Executable file
@ -0,0 +1,72 @@
|
|||||||
|
source "$(dirname -- "$0")"/run_integration.sh
|
||||||
|
|
||||||
|
# Toolchains for little-endian, 64-bit ARMv8 for GNU/Linux systems
|
||||||
|
function set_aarch64-linux-gnu() {
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=aarch64-linux-gnu
|
||||||
|
QEMU_ARCH=aarch64
|
||||||
|
}
|
||||||
|
|
||||||
|
# Toolchains for little-endian, hard-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
function set_arm-linux-gnueabihf() {
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=arm-linux-gnueabihf
|
||||||
|
QEMU_ARCH=arm
|
||||||
|
}
|
||||||
|
|
||||||
|
# Toolchains for little-endian, 32-bit ARMv8 for GNU/Linux systems
|
||||||
|
function set_armv8l-linux-gnueabihf() {
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=armv8l-linux-gnueabihf
|
||||||
|
QEMU_ARCH=arm
|
||||||
|
}
|
||||||
|
|
||||||
|
# Toolchains for little-endian, soft-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
function set_arm-linux-gnueabi() {
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=arm-linux-gnueabi
|
||||||
|
QEMU_ARCH=arm
|
||||||
|
}
|
||||||
|
|
||||||
|
# Toolchains for big-endian, 64-bit ARMv8 for GNU/Linux systems
|
||||||
|
function set_aarch64_be-linux-gnu() {
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=aarch64_be-linux-gnu
|
||||||
|
QEMU_ARCH=""
|
||||||
|
}
|
||||||
|
|
||||||
|
# Toolchains for big-endian, hard-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
function set_armeb-linux-gnueabihf() {
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=armeb-linux-gnueabihf
|
||||||
|
QEMU_ARCH=""
|
||||||
|
}
|
||||||
|
|
||||||
|
# Toolchains for big-endian, soft-float, 32-bit ARMv7 (and earlier) for GNU/Linux systems
|
||||||
|
function set_armeb-linux-gnueabi() {
|
||||||
|
TOOLCHAIN=LINARO
|
||||||
|
TARGET=armeb-linux-gnueabi
|
||||||
|
QEMU_ARCH=""
|
||||||
|
}
|
||||||
|
|
||||||
|
function set_native() {
|
||||||
|
TOOLCHAIN=NATIVE
|
||||||
|
TARGET=native
|
||||||
|
QEMU_ARCH=""
|
||||||
|
}
|
||||||
|
|
||||||
|
ENVIRONMENTS="
|
||||||
|
set_aarch64-linux-gnu
|
||||||
|
set_arm-linux-gnueabihf
|
||||||
|
set_armv8l-linux-gnueabihf
|
||||||
|
set_arm-linux-gnueabi
|
||||||
|
set_aarch64_be-linux-gnu
|
||||||
|
set_armeb-linux-gnueabihf
|
||||||
|
set_armeb-linux-gnueabi
|
||||||
|
set_native
|
||||||
|
"
|
||||||
|
|
||||||
|
for SET_ENVIRONMENT in ${ENVIRONMENTS}; do
|
||||||
|
${SET_ENVIRONMENT}
|
||||||
|
expand_environment_and_integrate
|
||||||
|
done
|
Loading…
x
Reference in New Issue
Block a user