Skip to content

fix: relocatable installation (#9) #19

fix: relocatable installation (#9)

fix: relocatable installation (#9) #19

Workflow file for this run

name: CI
on:
pull_request:
push:
branches: [ main ]
tags: [ '*' ]
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
defaults:
run:
shell: bash
jobs:
stringspinner:
runs-on: ubuntu-latest
container:
image: archlinux/archlinux:latest
steps:
- name: update container packages
run: pacman -Syu --noconfirm
- name: install dependencies
run: |
pkgs=(
fmt
gcc
gcc-fortran
git
meson
ninja
pkgconf
pythia8
python
tree
)
pacman -S --noconfirm ${pkgs[*]}
echo "[+++++] PACKAGE VERSIONS:"
for pkg in ${pkgs[@]}; do
echo "$pkg: $(pacman -Qi $pkg | grep -E '^Version')"
done
- name: git checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: meson setup
run: meson setup build --prefix=$(pwd)/install
- run: meson install
working-directory: build
- run: tree install
- run: meson test
working-directory: build
- name: test installation
run: install/bin/stringspinner --num-events 1
- name: test relocatability
run: |
mkdir relocated
cp -r install relocated/
relocated/install/bin/stringspinner --num-events 1
- name: test symlinking
run: |
ln -sv install/bin/stringspinner
./stringspinner --num-events 1