Skip to content

Commit 47dd10e

Browse files
bindea-cristianAlexandraTrifan
authored andcommitted
ci/arm: change cross-compiler to one with armv7 flags
Signed-off-by: Bindea Cristian <cristian.bindea@analog.com>
1 parent 0732fb1 commit 47dd10e

File tree

2 files changed

+20
-13
lines changed

2 files changed

+20
-13
lines changed

ci/arm/arm_build_config.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,10 @@ if [ $TOOLCHAIN_HOST == "aarch64-linux-gnu" ]; then
9191
elif [ $TOOLCHAIN_HOST == "arm-linux-gnueabihf" ]; then
9292
# bookwork
9393
#CROSSCOMPILER_DOWNLOAD_LINK=https://sourceforge.net/projects/raspberry-pi-cross-compilers/files/Raspberry%20Pi%20GCC%20Cross-Compiler%20Toolchains/Bookworm/GCC%2012.2.0/Raspberry%20Pi%202%2C%203/cross-gcc-12.2.0-pi_2-3.tar.gz
94-
CROSSCOMPILER_DOWNLOAD_LINK=https://sourceforge.net/projects/raspberry-pi-cross-compilers/files/Raspberry%20Pi%20GCC%20Cross-Compiler%20Toolchains/Bullseye/GCC%2010.2.0/Raspberry%20Pi%203A%2B%2C%203B%2B%2C%204%2C%205/cross-gcc-10.2.0-pi_3%2B.tar.gz
94+
# bullseye, with armv8 flags
95+
#CROSSCOMPILER_DOWNLOAD_LINK=https://sourceforge.net/projects/raspberry-pi-cross-compilers/files/Raspberry%20Pi%20GCC%20Cross-Compiler%20Toolchains/Bullseye/GCC%2010.2.0/Raspberry%20Pi%203A%2B%2C%203B%2B%2C%204%2C%205/cross-gcc-10.2.0-pi_3%2B.tar.gz
96+
# compiler with armv7 flags
97+
CROSSCOMPILER_DOWNLOAD_LINK=https://sourceforge.net/projects/raspberry-pi-cross-compilers/files/Raspberry%20Pi%20GCC%20Cross-Compiler%20Toolchains/Bullseye/GCC%2010.2.0/Raspberry%20Pi%202%2C%203/cross-gcc-10.2.0-pi_2-3.tar.gz
9598
fi
9699

97100
CMAKE_DOWNLOAD_LINK=https://github.com/Kitware/CMake/releases/download/v3.29.0-rc2/cmake-3.29.0-rc2-linux-x86_64.tar.gz

ci/arm/arm_build_process.sh

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -220,18 +220,22 @@ build_gnuradio() {
220220
-DENABLE_POSTINSTALL=OFF \
221221
"
222222

223-
if [ $TOOLCHAIN_HOST == "arm-linux-gnueabihf" ]; then
224-
PYTHON_WRAPPER="$STAGING_AREA/python-wrapper.sh"
225-
echo '#!/bin/bash' > $PYTHON_WRAPPER
226-
echo "
227-
LOADER="$SYSROOT/lib/ld-linux-armhf.so.3"
228-
LIB_PATH="$SYSROOT/usr/lib/arm-linux-gnueabihf"
229-
PYTHON_BIN="$SYSROOT/usr/bin/python3"
230-
" >> $PYTHON_WRAPPER
231-
echo 'exec $LOADER --library-path $LIB_PATH $PYTHON_BIN "$@"'>> $PYTHON_WRAPPER
232-
chmod +x $PYTHON_WRAPPER
233-
CURRENT_BUILD_CMAKE_OPTS="${CURRENT_BUILD_CMAKE_OPTS} -DPYTHON_EXECUTABLE=${PYTHON_WRAPPER} \ "
234-
fi
223+
# This is not needed anymore, (don't know why) but it was used as a workaround to execute the python binary, from the sysroot, in the host machine
224+
# it was needed because, for some reason, the gnuradio build process needed to execute the binary at build time
225+
# if [ $TOOLCHAIN_HOST == "arm-linux-gnueabihf" ]; then
226+
# PYTHON_WRAPPER="$STAGING_AREA/python-wrapper.sh"
227+
# echo '#!/bin/bash' > $PYTHON_WRAPPER
228+
# echo "
229+
# LOADER="$SYSROOT/lib/ld-linux-armhf.so.3"
230+
# LIB_PATH="$SYSROOT/usr/lib/arm-linux-gnueabihf"
231+
# PYTHON_BIN="$SYSROOT/usr/bin/python3"
232+
# " >> $PYTHON_WRAPPER
233+
# echo 'exec $LOADER --library-path $LIB_PATH $PYTHON_BIN "$@"'>> $PYTHON_WRAPPER
234+
# chmod +x $PYTHON_WRAPPER
235+
# CURRENT_BUILD_CMAKE_OPTS="${CURRENT_BUILD_CMAKE_OPTS} -DPYTHON_EXECUTABLE=${PYTHON_WRAPPER} \ "
236+
# fi
237+
# although a better approch is to install qemu and to use:
238+
# exec qemu-arm -cpu cortex-a9 -L /home/runner/scopy/ci/arm/staging/sysroot $PYTHON_BIN "$@"
235239

236240
build_with_cmake
237241
sudo make install

0 commit comments

Comments
 (0)