diff --git a/.github/workflows/kuiperbuild.yml b/.github/workflows/kuiperbuild.yml index 8072fa4bbc..f9841d5ded 100644 --- a/.github/workflows/kuiperbuild.yml +++ b/.github/workflows/kuiperbuild.yml @@ -23,14 +23,32 @@ jobs: shell: bash run: | sudo chown -R 1000:1000 $GITHUB_WORKSPACE + + set "BUILD_HOST=ubuntu-20.04" + set "USERNAME=runner" + docker run \ --mount type=bind,source="$GITHUB_WORKSPACE",target=/home/runner/scopy \ - cristianbindea/scopy2-kuiper:latest /bin/bash -c 'id && cd /home/runner/scopy && ./ci/kuiper/kuiper_build_process.sh install_packages download_cmake download_crosscompiler move_sysroot build_scopy build_iio-emu create_appdir create_appimage move_appimage' + -e BUILD_HOST=$BUILD_HOST \ + -e USERNAME=$USERNAME \ + -e GITHUB_SERVER_URL=$GITHUB_SERVER_URL \ + -e GITHUB_API_URL=$GITHUB_API_URL \ + -e GITHUB_RUN_ID=$GITHUB_RUN_ID \ + -e GITHUB_RUN_NUMBER=$GITHUB_RUN_NUMBER \ + -e GITHUB_JOB=$GITHUB_JOB \ + -e RUNNER_ARCH=$RUNNER_ARCH \ + -e SHELL="/bin/bash" + cristianbindea/scopy2-kuiper:latest /bin/bash -c 'cd /home/runner/scopy && ./ci/kuiper/kuiper_build_process.sh install_packages download_cmake download_crosscompiler move_sysroot build_scopy build_iio-emu create_appdir create_appimage move_appimage' - name: Set short git commit SHA shell: bash run: echo "commit_sha=$(git rev-parse --short ${{ github.sha }})" >> "$GITHUB_ENV" + - name: Setup upterm session + uses: lhotari/action-upterm@v1 + with: + wait-timeout-minutes: 3 + - uses: actions/upload-artifact@v4 with: name: scopy-linux-armhf-${{ env.commit_sha }} diff --git a/ci/kuiper/copy-deps.sh b/ci/kuiper/copy-deps.sh index 57a08ce14a..142f27b9df 100755 --- a/ci/kuiper/copy-deps.sh +++ b/ci/kuiper/copy-deps.sh @@ -1,6 +1,8 @@ #!/bin/bash set -ex +export PS4='+(${LINENO}): ${FUNCNAME[0]:+${FUNCNAME[0]}(): }' + SRC_DIR=$(git rev-parse --show-toplevel) source $SRC_DIR/ci/kuiper/kuiper_build_config.sh @@ -9,9 +11,8 @@ LOCATION=$2 if [ ! -f "${SRC_DIR}"/ci/kuiper/ldd-mod ]; then - ls /usr/arm-linux-gnueabihf/lib - ls /usr/arm-linux-gnueabihf/lib/ld-2.31.so - ls /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.3 + export + printenv sed 's|.*RTLDLIST=.*|RTLDLIST="/usr/arm-linux-gnueabihf/lib/ld-2.31.so /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.3"|' /usr/bin/ldd | tee "${SRC_DIR}"/ci/kuiper/ldd-mod chmod +x "${SRC_DIR}"/ci/kuiper/ldd-mod fi @@ -19,17 +20,6 @@ fi export LD_LIBRARY_PATH="${APP_DIR}/usr/lib:${SYSROOT}/lib:${SYSROOT}/lib/arm-linux-gnueabihf:${SYSROOT}/usr/arm-linux-gnueabihf/lib:${SYSROOT}/usr/local/qt5.15/lib:${SYSROOT}/usr/local/lib:${SRC_DIR}/build" LIBS_ARRAY=() run_ldd(){ - - if [ ! -z "$(${SRC_DIR}/ci/kuiper/ldd-mod $1 | grep "not found")" ]; then - echo "--- LIB NOT FOUND" - ${SRC_DIR}/ci/kuiper/ldd-mod $1 - exit 1 - fi - if [ ! -z "$(${SRC_DIR}/ci/kuiper/ldd-mod $1 | grep "not a dynamic executable")" ]; then - echo "--- LDD ERROR" - exit 1 - fi - for library in $("${SRC_DIR}"/ci/kuiper/ldd-mod "$1" | cut -d '>' -f 2 | awk '{print $1}') do # check if the library exists at that path and if it was processed already diff --git a/ci/kuiper/kuiper_build_config.sh b/ci/kuiper/kuiper_build_config.sh index 3948082f3e..99ac443543 100644 --- a/ci/kuiper/kuiper_build_config.sh +++ b/ci/kuiper/kuiper_build_config.sh @@ -56,3 +56,17 @@ CMAKE_DOWNLOAD_LINK=https://github.com/Kitware/CMake/releases/download/v3.29.0-r KUIPER_DOWNLOAD_LINK=https://swdownloads.analog.com/cse/kuiper/image_2023-12-13-ADI-Kuiper-full.zip QT_DOWNLOAD_LINK=http://download.qt.io/archive/qt/5.15/5.15.2/single/qt-everywhere-src-5.15.2.tar.xz SYSROOT_RELATIVE_LINKS=https://raw.githubusercontent.com/abhiTronix/rpi_rootfs/master/scripts/sysroot-relativelinks.py + +echo "====SHEL====" +echo $SHELL +echo "==============" +echo "====printenv====" +printenv +echo "==============" +echo "====export====" +export +echo "==============" +echo "====env====" +export +echo "==============" +