aboutsummaryrefslogtreecommitdiff
path: root/test/postinstall/c_app
diff options
context:
space:
mode:
authorMike Taves <mwtoews@gmail.com>2022-01-13 21:55:21 +1300
committerGitHub <noreply@github.com>2022-01-13 21:55:21 +1300
commit69962fefc233ba06450b353073a2db4a9fce3ceb (patch)
tree1c2fdc07d6172fc9f9d33c3d6615740bb6ad92c4 /test/postinstall/c_app
parent0e26f598ef4b4930dcf3344cf6a430c984e62385 (diff)
downloadPROJ-69962fefc233ba06450b353073a2db4a9fce3ceb.tar.gz
PROJ-69962fefc233ba06450b353073a2db4a9fce3ceb.zip
Specify CMAKE_INSTALL_RPATH for macOS; use -rpath LDFLAGS for tests (#3009)
Diffstat (limited to 'test/postinstall/c_app')
-rw-r--r--test/postinstall/c_app/CMakeLists.txt2
-rw-r--r--test/postinstall/c_app/Makefile.am2
-rw-r--r--test/postinstall/c_app/makefile.mak2
-rwxr-xr-xtest/postinstall/c_app/test_ldd.sh4
-rwxr-xr-xtest/postinstall/c_app/test_libpath.sh6
5 files changed, 9 insertions, 7 deletions
diff --git a/test/postinstall/c_app/CMakeLists.txt b/test/postinstall/c_app/CMakeLists.txt
index a493849b..a5ada471 100644
--- a/test/postinstall/c_app/CMakeLists.txt
+++ b/test/postinstall/c_app/CMakeLists.txt
@@ -28,7 +28,7 @@ endif()
set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/..)
include(common)
-add_test_ldd(c_app proj)
+add_test_libpath(c_app proj)
add_test_transform(c_app)
add_test_searchpath(c_app)
add_test_version(c_app)
diff --git a/test/postinstall/c_app/Makefile.am b/test/postinstall/c_app/Makefile.am
index 356034ba..912c5431 100644
--- a/test/postinstall/c_app/Makefile.am
+++ b/test/postinstall/c_app/Makefile.am
@@ -3,7 +3,7 @@ c_app_SOURCES = c_app.c
c_app_CFLAGS = $(PROJ_CFLAGS)
c_app_LDADD = $(PROJ_LIBS)
TESTS = \
- test_ldd.sh \
+ test_libpath.sh \
test_transform.sh \
test_searchpath.sh \
test_version.sh
diff --git a/test/postinstall/c_app/makefile.mak b/test/postinstall/c_app/makefile.mak
index d6c1c8de..3e29d4b1 100644
--- a/test/postinstall/c_app/makefile.mak
+++ b/test/postinstall/c_app/makefile.mak
@@ -1,7 +1,7 @@
PROGRAM = c_app
OBJECTS = $(addsuffix .o,$(PROGRAM))
TESTS = \
- test_ldd.sh \
+ test_libpath.sh \
test_transform.sh \
test_searchpath.sh \
test_version.sh
diff --git a/test/postinstall/c_app/test_ldd.sh b/test/postinstall/c_app/test_ldd.sh
deleted file mode 100755
index 9750db16..00000000
--- a/test/postinstall/c_app/test_ldd.sh
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-. ../common.sh
-
-test_ldd c_app libproj
diff --git a/test/postinstall/c_app/test_libpath.sh b/test/postinstall/c_app/test_libpath.sh
new file mode 100755
index 00000000..57b3aa41
--- /dev/null
+++ b/test/postinstall/c_app/test_libpath.sh
@@ -0,0 +1,6 @@
+#!/bin/sh
+. ../common.sh
+
+EXPECTED_LIBPATH="$(pkg-config proj --variable=libdir)"
+
+test_libpath c_app "${EXPECTED_LIBPATH}" libproj