--- testsuite/dlopen-test.c.orig 2017-04-24 16:05:46.000000000 -0400 +++ testsuite/dlopen-test.c 2017-04-24 16:05:56.000000000 -0400 @@ -9,7 +9,7 @@ main (int argc UNUSED, char **argv UNUSED) { #if HAVE_LIBDL - void *handle = dlopen ("../libnettle.so", RTLD_NOW); + void *handle = dlopen ("../libnettle.dylib", RTLD_NOW); int (*get_version)(void); if (!handle) { --- run-tests.orig 2017-04-24 16:43:46.000000000 -0400 +++ run-tests 2017-04-24 16:44:27.000000000 -0400 @@ -58,9 +58,9 @@ testname=`basename "$1" .exe` testname=`basename "$testname" -test` if [ -z "$EMULATOR" ] || head -1 "$1" | grep '^#!' > /dev/null; then - "$1" $testflags + DYLD_LIBRARY_PATH=../.lib "$1" $testflags else - $EMULATOR "$1" $testflags + DYLD_LIBRARY_PATH=../.lib $EMULATOR "$1" $testflags fi case "$?" in 0) --- examples/rsa-encrypt-test.orig 2017-04-24 16:48:35.000000000 -0400 +++ examples/rsa-encrypt-test 2017-04-24 16:49:07.000000000 -0400 @@ -7,12 +7,12 @@ data="$srcdir/nettle-benchmark.c" if [ -x rsa-encrypt$EXEEXT ] ; then - if $EMULATOR ./rsa-encrypt -r rsa-decrypt$EXEEXT testkey.pub < "$data" > testciphertext ; then + if DYLD_LIBRARY_PATH=../.lib $EMULATOR ./rsa-encrypt -r rsa-decrypt$EXEEXT testkey.pub < "$data" > testciphertext ; then : else exit 1 fi - if $EMULATOR ./rsa-decrypt testkey < testciphertext > testcleartext ; then + if DYLD_LIBRARY_PATH=../.lib $EMULATOR ./rsa-decrypt testkey < testciphertext > testcleartext ; then : else exit 1