aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordundargoc <gocdundar@gmail.com>2024-01-20 18:24:45 +0100
committerdundargoc <33953936+dundargoc@users.noreply.github.com>2024-01-22 12:38:27 +0100
commitb4da4783f98837efb7192a3e5a40dd491aeb1491 (patch)
treef863afa8f8216a1e2bdc6177ae8543b467cbcf6e
parent1233ac467de7504b277425988ef9be7f8d3a9626 (diff)
downloadrneovim-b4da4783f98837efb7192a3e5a40dd491aeb1491.tar.gz
rneovim-b4da4783f98837efb7192a3e5a40dd491aeb1491.tar.bz2
rneovim-b4da4783f98837efb7192a3e5a40dd491aeb1491.zip
build: make genappimage.sh work with existing CMAKE_INSTALL_PREFIX
Using CMAKE_INSTALL_PREFIX is unreliable as it's a cache variable, meaning the users previous value will be used if not supplied. Instead, use the `--prefix` flag which is guaranteed to always work.
-rwxr-xr-xscripts/genappimage.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/genappimage.sh b/scripts/genappimage.sh
index b0bf186f85..0ad5e803e4 100755
--- a/scripts/genappimage.sh
+++ b/scripts/genappimage.sh
@@ -26,8 +26,8 @@ APP_DIR="$APP.AppDir"
########################################################################
# Build and install nvim into the AppImage
-make CMAKE_BUILD_TYPE="${NVIM_BUILD_TYPE}" CMAKE_EXTRA_FLAGS="-DCMAKE_INSTALL_PREFIX=${APP_DIR}/usr -DCMAKE_INSTALL_MANDIR=man"
-make install
+make CMAKE_BUILD_TYPE="${NVIM_BUILD_TYPE}"
+cmake --install build --prefix="$APP_BUILD_DIR/${APP_DIR}/usr"
########################################################################
# Get helper functions and move to AppDir
@@ -52,7 +52,7 @@ fi
chmod +x "$APP_BUILD_DIR"/linuxdeploy-x86_64.AppImage
# metainfo is not packaged automatically by linuxdeploy
-mkdir "$APP_DIR/usr/share/metainfo/"
+mkdir -p "$APP_DIR/usr/share/metainfo/"
cp "$ROOT_DIR/runtime/nvim.appdata.xml" "$APP_DIR/usr/share/metainfo/"
cd "$APP_DIR" || exit