cleanup: PKGBUILD should use proper variables

This commit is contained in:
Almamu 2024-06-07 12:06:20 +02:00
parent f74a19591a
commit 4bc5205034

View File

@ -27,7 +27,7 @@ pkgver() {
build() { build() {
cmake -B build -S "$pkgname" \ cmake -B build -S "$pkgname" \
-DCMAKE_BUILD_TYPE='Release' \ -DCMAKE_BUILD_TYPE='Release' \
-DCMAKE_INSTALL_PREFIX='/opt/linux-wallpaperengine' \ -DCMAKE_INSTALL_PREFIX="/opt/${_pkgname}" \
-Wno-dev -Wno-dev
cmake --build build cmake --build build
} }
@ -36,8 +36,8 @@ package() {
DESTDIR="$pkgdir" cmake --install build DESTDIR="$pkgdir" cmake --install build
# create forwarding script # create forwarding script
install -d -m755 "${pkgdir}/usr/bin" install -d -m755 "${pkgdir}/usr/bin"
echo "#!/bin/bash" > $pkgdir/usr/bin/linux-wallpaperengine echo "#!/bin/bash" > ${pkgdir}/usr/bin/${_pkgname}
echo "cd /opt/linux-wallpaperengine; ./linux-wallpaperengine \$*" >> $pkgdir/usr/bin/linux-wallpaperengine echo "cd /opt/${_pkgname}; ./linux-wallpaperengine \$*" >> ${pkgdir}/usr/bin/${_pkgname}
chmod +x $pkgdir/usr/bin/linux-wallpaperengine chmod +x ${pkgdir}/usr/bin/${_pkgname}
chmod +x $pkgdir/opt/linux-wallpaperengine/linux-wallpaperengine chmod +x ${pkgdir}/opt/${_pkgname}/linux-wallpaperengine
} }