summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt1
-rw-r--r--[-rwxr-xr-x]macosx/install-fail-tool4
-rw-r--r--macosx/make-app-bundle.sh5
-rw-r--r--macosx/opentrack.app/Contents/Info.plist2
-rwxr-xr-xmacosx/opentrack.sh4
-rw-r--r--macosx/qt.conf2
6 files changed, 9 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b74ec7f4..3363f14e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -545,7 +545,6 @@ endif()
install(DIRECTORY "${CMAKE_SOURCE_DIR}/bin/camera" DESTINATION .)
if(APPLE)
- install(FILES "${CMAKE_SOURCE_DIR}/macosx/qt.conf" DESTINATION .)
install(CODE "
execute_process(COMMAND /bin/sh \"${CMAKE_SOURCE_DIR}/macosx/make-app-bundle.sh\"
\"${CMAKE_SOURCE_DIR}/macosx\"
diff --git a/macosx/install-fail-tool b/macosx/install-fail-tool
index 0f34c3a1..a5464c18 100755..100644
--- a/macosx/install-fail-tool
+++ b/macosx/install-fail-tool
@@ -4,7 +4,7 @@ test -n "$1" || exit 1
dir="$1"
-for i in "$dir"/* "$dir"/*/*; do
+for i in "$dir"/* "$dir"/*/* "$dir"/*/*/*; do
{ test -x "$i" && test -f "$i"; } || continue
case "$i" in
*.dll|*.exe) continue ;;
@@ -13,7 +13,7 @@ for i in "$dir"/* "$dir"/*/*; do
case "$i" in
*.dylib|*.bin) strip -x "$i" ;; esac
echo ---- $i ----
- install_name_tool -id "@executable_path/$(basename -- "$i")" "$i"
+ install_name_tool -id "@executable_path/$(echo "$i" | sed -e "s,^$dir/,,")" "$i"
otool -L "$i" | awk '{ print $1 }' |
while read l; do
diff --git a/macosx/make-app-bundle.sh b/macosx/make-app-bundle.sh
index 7e79d6db..d0588ae2 100644
--- a/macosx/make-app-bundle.sh
+++ b/macosx/make-app-bundle.sh
@@ -14,16 +14,15 @@ test -n "$version" || exit 1
tmp="$(mktemp -d "/tmp/$APPNAME-tmp.XXXXXXX")"
test $? -eq 0 || exit 1
-"$dir/install-fail-tool" "$install"
+sh "$dir/install-fail-tool" "$install"
cp -R "$dir/opentrack.app" "$tmp/" || exit 1
cp -R "$install" "$tmp/$APPNAME.app/Contents/MacOS" || exit 1
sed -i '' -e "s#@OPENTRACK-VERSION@#$version#g" "$tmp/$APPNAME.app/Contents/Info.plist" || exit 1
-#cp "$dir/qt.conf" "$tmp/$APPNAME.app/Contents/MacOS" || exit 1
-
mkdir "$tmp/$APPNAME.iconset" || exit 1
mkdir "$tmp/$APPNAME.app/Contents/Resources" || exit 1
+cp "$dir"/opentrack.sh "$tmp/$APPNAME.app/Contents/MacOS" || exit 1
sips -z 16 16 "$dir/../facetracknoir/images/facetracknoir.png" --out "$tmp/$APPNAME.iconset/icon_16x16.png" || exit 1
sips -z 32 32 "$dir/../facetracknoir/images/facetracknoir.png" --out "$tmp/$APPNAME.iconset/icon_16x16@2x.png" || exit 1
diff --git a/macosx/opentrack.app/Contents/Info.plist b/macosx/opentrack.app/Contents/Info.plist
index ed4b0b05..41ca402a 100644
--- a/macosx/opentrack.app/Contents/Info.plist
+++ b/macosx/opentrack.app/Contents/Info.plist
@@ -5,7 +5,7 @@
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
- <string>opentrack.bin</string>
+ <string>opentrack.sh</string>
<key>CFBundleIdentifier</key>
<string>com.github.opentrack</string>
<key>CFBundleName</key>
diff --git a/macosx/opentrack.sh b/macosx/opentrack.sh
new file mode 100755
index 00000000..62ad01a5
--- /dev/null
+++ b/macosx/opentrack.sh
@@ -0,0 +1,4 @@
+#!/bin/sh
+
+dir="$(dirname -- "$0")"
+exec "$dir"/opentrack.bin -platformpluginpath "$dir" "$@"
diff --git a/macosx/qt.conf b/macosx/qt.conf
deleted file mode 100644
index e69f24eb..00000000
--- a/macosx/qt.conf
+++ /dev/null
@@ -1,2 +0,0 @@
-[Paths]
-Plugins = .