Skip to content

Commit

Permalink
fix: macOS rpath and dynamic library issues (#73)
Browse files Browse the repository at this point in the history
  • Loading branch information
c-dilks authored Jan 16, 2024
1 parent 5f24b6e commit ef8a57e
Show file tree
Hide file tree
Showing 14 changed files with 564 additions and 360 deletions.
13 changes: 4 additions & 9 deletions .github/test-consumer-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,15 @@
set -e

# args
[ $# -lt 1 ] && echo "USAGE: $0 [tool] [test args]..." >&2 && exit 2
[ $# -ne 1 ] && echo "USAGE: $0 [tool]" >&2 && exit 2
tool=$1
shift

# source, build, and install directories
source_dir=examples/build_with_$tool
build_dir=build-consumer
install_dir=install-consumer
mkdir -p $install_dir
install_dir=$(realpath $install_dir)

# executable
test_executable=iguana-example-00-basic
install_dir=$(cd $install_dir && pwd -P)

# print and execute a command
exe() {
Expand All @@ -32,18 +28,17 @@ case $tool in
exe cmake -S $source_dir -B $build_dir
exe cmake --build $build_dir
exe cmake --install $build_dir --prefix $install_dir
exe $install_dir/bin/$test_executable "$@"
;;
make)
pushd $source_dir
exe make
popd
exe $source_dir/bin/$test_executable "$@"
mkdir -pv $install_dir
mv -v $source_dir/bin $install_dir/
;;
meson)
exe meson setup --prefix=$install_dir $build_dir $source_dir
exe meson install -C $build_dir
exe $install_dir/bin/$test_executable "$@"
;;
*)
echo "ERROR: unknown tool '$tool'" >&2
Expand Down
Loading

0 comments on commit ef8a57e

Please sign in to comment.