Add basic PKGBUILD for building on Arch/Manjaro
PKGBUILD format is described on the Arch wiki https://wiki.archlinux.org/index.php/Creating_packages Arch User Repository is described here https://wiki.archlinux.org/index.php/Arch_User_Repository The AUR package can be found here https://aur.archlinux.org/packages/ovras/
This commit is contained in:
@@ -19,6 +19,7 @@ Adds an overlay to the OpenVR dashboard that allows access to advanced settings
|
|||||||
* [Standalone](#standalone)
|
* [Standalone](#standalone)
|
||||||
* [Linux](#linux)
|
* [Linux](#linux)
|
||||||
* [AppImage](#appimage)
|
* [AppImage](#appimage)
|
||||||
|
* [Arch/Manjaro](#archmanjaro)
|
||||||
* [Building from Source](#building-from-source)
|
* [Building from Source](#building-from-source)
|
||||||
* [Bindings](#bindings)
|
* [Bindings](#bindings)
|
||||||
* [Music](#music)
|
* [Music](#music)
|
||||||
@@ -107,6 +108,11 @@ Simply double click the AppImage once downloaded to run it. Depending on your di
|
|||||||
|
|
||||||
If the AppImage doesn't work for whatever reason, please create an issue [here](https://github.com/OpenVR-Advanced-Settings/OpenVR-AdvancedSettings/issues/new/choose) describing the problem and try compiling from source.
|
If the AppImage doesn't work for whatever reason, please create an issue [here](https://github.com/OpenVR-Advanced-Settings/OpenVR-AdvancedSettings/issues/new/choose) describing the problem and try compiling from source.
|
||||||
|
|
||||||
|
### Arch/Manjaro
|
||||||
|
|
||||||
|
OpenVR Advanced Settings is on the [Arch User Repository](https://wiki.archlinux.org/index.php/Arch_User_Repository) as `ovras`.
|
||||||
|
Manjaro users can [enable](https://wiki.manjaro.org/index.php/Arch_User_Repository) the AUR and install this package using `pamac build ovras`.
|
||||||
|
|
||||||
### Building from Source
|
### Building from Source
|
||||||
|
|
||||||
Detailed instructions are available [here](docs/building_for_linux.md).
|
Detailed instructions are available [here](docs/building_for_linux.md).
|
||||||
|
|||||||
@@ -0,0 +1,69 @@
|
|||||||
|
# Maintainer: Vitaly Utkin <vautkin AT teknik DOT io>
|
||||||
|
pkgname=ovras
|
||||||
|
pkgver=4.0.1
|
||||||
|
pkgrel=2
|
||||||
|
epoch=0
|
||||||
|
pkgdesc="Advanced settings and custom behavior for SteamVR using OpenVR."
|
||||||
|
arch=("x86_64")
|
||||||
|
url="https://github.com/OpenVR-Advanced-Settings/OpenVR-AdvancedSettings"
|
||||||
|
license=("GPL")
|
||||||
|
depends=("qt5-declarative"
|
||||||
|
"qt5-multimedia"
|
||||||
|
"libudev0-shim"
|
||||||
|
"mesa")
|
||||||
|
optdepends=("dbus: media player support"
|
||||||
|
"xorg-server: send keyboard keys")
|
||||||
|
source=("https://github.com/OpenVR-Advanced-Settings/OpenVR-AdvancedSettings/archive/v$pkgver.tar.gz")
|
||||||
|
sha256sums=("371d5a3f81a986ec5b3446c62a36cbf5eb951c97ea2b4a64752c4709bb8e6c76")
|
||||||
|
|
||||||
|
build() {
|
||||||
|
cd "OpenVR-AdvancedSettings-$pkgver"
|
||||||
|
|
||||||
|
_additionalOptions=
|
||||||
|
|
||||||
|
# Attempting to compile without package will result in compile error
|
||||||
|
pacman -Qi xorg-server >/dev/null 2>&1
|
||||||
|
if [ $? -ne 0 ]; then
|
||||||
|
_additionalOptions="CONFIG+=noX11"
|
||||||
|
echo "X11 features disabled."
|
||||||
|
else
|
||||||
|
echo "X11 features enabled."
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Attempting to compile without package will result in compile error
|
||||||
|
pacman -Qi dbus >/dev/null 2>&1
|
||||||
|
if [ $? -ne 0 ]; then
|
||||||
|
_additionalOptions+=" CONFIG+=noDBUS"
|
||||||
|
echo "DBUS features disabled."
|
||||||
|
else
|
||||||
|
echo "DBUS features enabled."
|
||||||
|
fi
|
||||||
|
|
||||||
|
qmake PREFIX="$pkgdir/opt/" $_additionalOptions
|
||||||
|
make
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
cd "OpenVR-AdvancedSettings-$pkgver"
|
||||||
|
|
||||||
|
# Add .desktop file
|
||||||
|
mkdir -p "$pkgdir/usr/share/applications"
|
||||||
|
cp "src/package_files/linux/AdvancedSettings.desktop" "$pkgdir/usr/share/applications/"
|
||||||
|
sed -i 's/Exec=.*/Exec=\/opt\/AdvancedSettings\/AdvancedSettings/' "$pkgdir/usr/share/applications/AdvancedSettings.desktop"
|
||||||
|
|
||||||
|
# Add correct desktop icon to desktop file
|
||||||
|
sed -i 's/Icon=.*/Icon=\/opt\/AdvancedSettings\/AdvancedSettings.png/' "$pkgdir/usr/share/applications/AdvancedSettings.desktop"
|
||||||
|
# Dir doesn't exist before `make install`
|
||||||
|
mkdir -p "$pkgdir/opt/AdvancedSettings/"
|
||||||
|
cp "src/res/img/icons/thumbicon.png" "$pkgdir/opt/AdvancedSettings/AdvancedSettings.png"
|
||||||
|
|
||||||
|
# Make program use correct working dir
|
||||||
|
echo "Path=/opt/AdvancedSettings" >> "$pkgdir/usr/share/applications/AdvancedSettings.desktop"
|
||||||
|
|
||||||
|
# Enable command line usage
|
||||||
|
mkdir -p "$pkgdir/usr/bin/"
|
||||||
|
ln -s /opt/AdvancedSettings/AdvancedSettings "$pkgdir/usr/bin/ovras"
|
||||||
|
|
||||||
|
# Install
|
||||||
|
make install
|
||||||
|
}
|
||||||
@@ -306,6 +306,9 @@ qmake
|
|||||||
make -j2
|
make -j2
|
||||||
```
|
```
|
||||||
|
|
||||||
|
A stable version can also be found on the [Arch User Repository](https://wiki.archlinux.org/index.php/Arch_User_Repository) as `ovras`.
|
||||||
|
It can be installed with `pamac build ovras`.
|
||||||
|
|
||||||
# Building
|
# Building
|
||||||
|
|
||||||
You will need the requirements above.
|
You will need the requirements above.
|
||||||
|
|||||||
Reference in New Issue
Block a user