diff options
Diffstat (limited to 'java/examples/datasets/JavaDatasetExample.sh.in')
-rw-r--r-- | java/examples/datasets/JavaDatasetExample.sh.in | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/java/examples/datasets/JavaDatasetExample.sh.in b/java/examples/datasets/JavaDatasetExample.sh.in index ae79416..7c47002 100644 --- a/java/examples/datasets/JavaDatasetExample.sh.in +++ b/java/examples/datasets/JavaDatasetExample.sh.in @@ -15,6 +15,7 @@ top_builddir=@top_builddir@ top_srcdir=@top_srcdir@ srcdir=@srcdir@ +IS_DARWIN="@H5_IS_DARWIN@" USE_FILTER_SZIP="@USE_FILTER_SZIP@" USE_FILTER_DEFLATE="@USE_FILTER_DEFLATE@" @@ -36,8 +37,8 @@ nerrors=0 # where the libs exist HDFLIB_HOME="$top_srcdir/java/lib" -BLDLIBDIR="$top_builddir/hdf5/lib" BLDDIR="." +BLDLIBDIR="$BLDDIR/testlibs" HDFTEST_HOME="$top_srcdir/java/examples/datasets" JARFILE=jar@PACKAGE_TARNAME@-@PACKAGE_VERSION@.jar TESTJARFILE=jar@PACKAGE_TARNAME@datasets.jar @@ -113,6 +114,13 @@ COPY_LIBFILES_TO_BLDLIBDIR() fi fi done + if [ "$IS_DARWIN" = "yes" ]; then + (cd $BLDLIBDIR; \ + install_name_tool -add_rpath @loader_path libhdf5_java.dylib; \ + exist_path=` otool -l libhdf5_java.dylib | grep libhdf5 | grep -v java | awk '{print $2}'`; \ + echo $exist_path; \ + install_name_tool -change $exist_path @rpath/libhdf5.dylib libhdf5_java.dylib) + fi # copy jar files. Used -f to make sure get a new copy for tstfile in $COPY_JARTESTFILES do |