use rpath=$ORIGIN instead of LD_LIBRARY_PATH

Hi

If libjvm.so is in the same directory as avian-dynamic, then there's
no need for LD_LIBRARY_PATH to include that directory, we can just set
the rpath in avian-dynamic to $ORIGIN when linking it. Working patch
attached.

Regards
Damjan
This commit is contained in:
Joel Dice 2013-02-08 09:34:26 -07:00
parent f9b3be0301
commit 07e3294937

View File

@ -1245,7 +1245,7 @@ ifdef msvc
-MANIFESTFILE:$(@).manifest
$(mt) -manifest $(@).manifest -outputresource:"$(@);1"
else
$(ld) $(driver-dynamic-objects) -L$(build) -ljvm $(lflags) $(no-lto) -o $(@)
$(ld) $(driver-dynamic-objects) -L$(build) -ljvm $(lflags) $(no-lto) -Wl,-rpath=\$$ORIGIN -z origin -o $(@)
endif
$(strip) $(strip-all) $(@)