diff --git a/package/darwin/dfhack b/package/darwin/dfhack new file mode 100755 index 000000000..62407342a --- /dev/null +++ b/package/darwin/dfhack @@ -0,0 +1,15 @@ +#!/bin/sh +PWD=`dirname "${0}"` +#thanks to Iriel for figuring this out +OSREV=`uname -r | cut -d. -f1` +if [ "$OSREV" -ge 11 ] ; then + export DYLD_INSERT_LIBRARIES=./hack/libdfhack.dylib + export DYLD_LIBRARY_PATH=${PWD}/hack:${PWD}/libs + export DYLD_FRAMEWORK_PATH=${PWD}/hack:${PWD}/libs +else + export DYLD_INSERT_LIBRARIES=./hack/libdfhack.dylib + export DYLD_FALLBACK_LIBRARY_PATH=${PWD}/hack:${PWD}/libs + export DYLD_FALLBACK_FRAMEWORK_PATH=${PWD}/hack:${PWD}/libs +fi +export DYLD_FORCE_FLAT_NAMESPACE=1 +cd "${PWD}"; ./dwarfort.exe diff --git a/package/darwin/dfhack-run b/package/darwin/dfhack-run new file mode 100755 index 000000000..865c8bd21 --- /dev/null +++ b/package/darwin/dfhack-run @@ -0,0 +1,9 @@ +#!/bin/sh + +DF_DIR=$(dirname "$0") +cd "${DF_DIR}" + +export DYLD_LIBRARY_PATH=${PWD}/hack:${PWD}/libs +export DYLD_FRAMEWORK_PATH=${PWD}/hack${PWD}/libs + +exec hack/dfhack-run "$@"