Debug LC_PATH #55
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CMake | |
on: | |
[ push, pull_request ] | |
env: | |
BUILD_TYPE: Release | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: [ ubuntu-24.04, ubuntu-22.04, macos-15, macos-14 ] | |
runs-on: ${{ matrix.os }} | |
env: | |
VDL2_TEST1: "--iq-file ${{github.workspace}}/test/vdl2_model_16b_1050kHz.wav --sample-format S16_LE --extended-header" | |
VDL2_TEST1_EXPECT: "20 2d 52 41 20 42 52 20 4f 56 43 30 30 35 0a|20 53 4c 50 31 33 35 0a" | |
VDL2_TEST1_RESULT: 2 | |
HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK: 1 | |
HOMEBREW_NO_INSTALL_UPGRADE: 1 | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Install packaged dependencies | |
run: | | |
if [[ "$RUNNER_OS" == "Linux" ]]; then sudo apt-get update; fi | |
if [[ "$RUNNER_OS" == "Linux" ]]; then sudo apt-get install libconfig++-dev libsoapysdr-dev librtlsdr-dev libzmq3-dev libprotobuf-c-dev; fi | |
if [[ "$RUNNER_OS" == "macOS" ]]; then brew update; fi | |
if [[ "$RUNNER_OS" == "macOS" ]]; then brew install libconfig soapysdr librtlsdr zmq protobuf-c ; fi | |
- name: Install libacars | |
run: | | |
cd "$RUNNER_TEMP" | |
git clone https://github.com/szpajder/libacars.git | |
cd libacars | |
if [[ "${{ github.ref_name }}" == "master" ]]; then branch=master; else branch=unstable; fi | |
echo "libacars branch used: $branch" | |
mkdir build | |
cd build | |
cmake .. | |
make -j | |
sudo make install | |
if [[ "$RUNNER_OS" == "Linux" ]]; then sudo ldconfig; fi | |
if [[ "$RUNNER_OS" == "macOS" ]]; then sudo update_dyld_shared_cache; fi | |
if [[ "$RUNNER_OS" == "macOS" ]]; then echo dumpvdl2 LC_RPATH; otool -l /usr/local/bin/dumpvdl2 | grep LC_RPATH; echo libacars LC_ID_DYLIB:; otool -l /usr/local/lib/libacars-2.dylib | grep -A 2 LC_ID_DYLIB; fi | |
- name: Configure CMake | |
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} | |
- name: Build | |
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} | |
- name: Install | |
run: sudo cmake --install ${{github.workspace}}/build | |
- name: Test run | |
run: | | |
/usr/local/bin/dumpvdl2 ${VDL2_TEST1} | |
res=$(/usr/local/bin/dumpvdl2 ${VDL2_TEST1} | egrep -c "${VDL2_TEST1_EXPECT}") | |
if [[ "x$res" = "x" ]]; then false; fi | |
if [[ $res -eq ${VDL2_TEST1_RESULT} ]]; then true; fi |