[openrgb] build from source, needs mbedtls
This commit is contained in:
parent
fb67878617
commit
d45728c1b2
1 changed files with 26 additions and 23 deletions
|
@ -10,34 +10,37 @@ PRGNAM=$(basename "$CWD")
|
||||||
PKG=$TMP/pkg-$PRGNAM
|
PKG=$TMP/pkg-$PRGNAM
|
||||||
|
|
||||||
ARCH=$(uname -m)
|
ARCH=$(uname -m)
|
||||||
BUILD=2
|
BUILD=1
|
||||||
VERSION=${VERSION:-0.9}
|
VERSION=${VERSION:-latest}
|
||||||
MAGIC_NUMBER=${MAGIC_NUMBER:-b5f46e3}
|
|
||||||
|
REPOSITORY=/home/installs/SlackBuilds/_repositories/$PRGNAM
|
||||||
|
|
||||||
rm -fr "$PKG" "${TMP:?}"/"$PRGNAM"
|
rm -fr "$PKG" "${TMP:?}"/"$PRGNAM"
|
||||||
|
|
||||||
mkdir -p "$PKG"
|
mkdir -p "$PKG"
|
||||||
|
|
||||||
mkdir -p "$PKG"/usr/bin/
|
# mise en place
|
||||||
wget -c "https://openrgb.org/releases/release_${VERSION}/OpenRGB_${VERSION}_x86_64_${MAGIC_NUMBER}.AppImage" -O "$PKG"/usr/bin/"$PRGNAM"
|
[ ! -e "$REPOSITORY" ] && git clone https://gitlab.com/CalcProgrammer1/OpenRGB.git "$REPOSITORY"
|
||||||
chmod +x "$PKG"/usr/bin/"$PRGNAM"
|
cd "$REPOSITORY" || exit 1
|
||||||
|
git pull --all
|
||||||
|
|
||||||
mkdir -p "$PKG"/usr/lib/udev/rules.d/
|
cp -R "$REPOSITORY" "$TMP"/"$PRGNAM"
|
||||||
wget -c "https://gitlab.com/CalcProgrammer1/OpenRGB/-/jobs/artifacts/master/raw/60-openrgb.rules?job=Linux+64+AppImage&inline=false" -O "$PKG"/usr/lib/udev/rules.d/60-openrgb.rules
|
cd "$TMP"/"$PRGNAM"/ || exit 1
|
||||||
|
[ "$VERSION" == "latest" ] && VERSION=$(git tag --sort=-taggerdate | head -n1)
|
||||||
|
[ "$VERSION" == "" ] && VERSION=trunk
|
||||||
|
[ "$VERSION" == "trunk" ] && VERSION="git_r$(git rev-list --count HEAD)_$(git log -1 --format=%h)" #|| git checkout $VERSION
|
||||||
|
|
||||||
mkdir -p "$PKG"/usr/share/applications/
|
qmake6 DOCS_DIR=/usr/doc/"$PRGNAM" MAN_DIR=/usr/man/man1 OpenRGB.pro
|
||||||
cat <<EOF > "$PKG"/usr/share/applications/"$PRGNAM".desktop
|
CFLAGS="$SLKCFLAGS" \
|
||||||
#!/usr/bin/env xdg-open
|
CXXFLAGS="$SLKCFLAGS" \
|
||||||
[Desktop Entry]
|
make
|
||||||
Type=Application
|
make INSTALL_ROOT="$PKG" install
|
||||||
Version=$VERSION
|
|
||||||
Name=$PRGNAM
|
find "$PKG" -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
|
||||||
GenericName=$PRGNAM
|
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
|
||||||
Comment=LEDs control
|
|
||||||
Exec=/usr/bin/$PRGNAM
|
find "$PKG"/usr/man -type f -exec gzip -9 {} \;
|
||||||
Terminal=false
|
for i in $( find "$PKG"/usr/man -type l ) ; do ln -s "$( readlink "$i" ).gz" "$i.gz" ; rm "$i" ; done
|
||||||
Categories=System
|
|
||||||
EOF
|
|
||||||
|
|
||||||
# correction
|
# correction
|
||||||
cd "$PKG" || exit 1
|
cd "$PKG" || exit 1
|
||||||
|
@ -76,9 +79,9 @@ $PRGNAM:
|
||||||
$PRGNAM:
|
$PRGNAM:
|
||||||
$PRGNAM:
|
$PRGNAM:
|
||||||
$PRGNAM: https://www.openrgb.org/
|
$PRGNAM: https://www.openrgb.org/
|
||||||
$PRGNAM:
|
$PRGNAM: REQUIRES: mbedtls
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
# empaquetage
|
# empaquetage
|
||||||
cd "$PKG" || exit 1
|
cd "$PKG" || exit 1
|
||||||
/sbin/makepkg --linkadd y --chown n --prepend "$OUTPUT/$PRGNAM-${VERSION}_AppImage-$ARCH-$BUILD$TAG.txz"
|
/sbin/makepkg --linkadd y --chown n --prepend "$OUTPUT/$PRGNAM-${VERSION}-$ARCH-$BUILD$TAG.txz"
|
||||||
|
|
Loading…
Reference in a new issue