diff --git a/cmake/aarch64-linux-gnu.cmake b/cmake/aarch64-linux-gnu.cmake new file mode 100644 index 0000000..e2a77e9 --- /dev/null +++ b/cmake/aarch64-linux-gnu.cmake @@ -0,0 +1,18 @@ +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) diff --git a/cmake/arm-linux-gnueabihf.cmake b/cmake/arm-linux-gnueabihf.cmake index 42e6d91..5f9fd71 100644 --- a/cmake/arm-linux-gnueabihf.cmake +++ b/cmake/arm-linux-gnueabihf.cmake @@ -4,7 +4,7 @@ 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(CMAKE_AR arm-linux-gnueabihf-ar CACHE FILEPATH "Archiver") SET(THREADS_PTHREAD_ARG "2" CACHE STRING "Forcibly set by CMakeLists.txt." FORCE) diff --git a/scripts/run_integration.sh b/scripts/run_integration.sh index a1f5fa7..7b16091 100755 --- a/scripts/run_integration.sh +++ b/scripts/run_integration.sh @@ -28,7 +28,6 @@ if [[ -n "${CROSS_COMPILE}" ]]; then # Run tests export QEMU=qemu-${QEMU_ARCH} export QEMU_LD_PREFIX=${TOOLCHAIN}/${TARGET}/libc - export LD_LIBRARY_PATH=${TOOLCHAIN}/${TARGET}/libc for test_binary in ${BUILD_DIR}/test/*_test; do ${QEMU} ${test_binary} done