extra/guvcview to 2.2.1-1

This commit is contained in:
Kevin Mihelich 2024-11-23 23:34:35 +00:00
parent 5d677ec42e
commit c795382707
2 changed files with 34 additions and 35 deletions

View file

@ -1,20 +1,20 @@
pkgbase = guvcview pkgbase = guvcview
pkgdesc = Simple interface for capturing and viewing video from v4l2 devices pkgdesc = Simple interface for capturing and viewing video from v4l2 devices
pkgver = 2.1.0 pkgver = 2.2.1
pkgrel = 5 pkgrel = 1
url = http://guvcview.sourceforge.net/ url = http://guvcview.sourceforge.net/
arch = x86_64 arch = x86_64
license = GPL3 license = GPL3
makedepends = intltool makedepends = cmake
depends = ffmpeg depends = ffmpeg
depends = gsl depends = gsl
depends = gtk3 depends = gtk3
depends = qt5-base depends = qt6-base
depends = portaudio depends = portaudio
noextract = guvcview-src-2.1.0-2.tar.bz2 noextract = guvcview-src-2.2.1-2.tar.bz2
options = !emptydirs options = !emptydirs
source = https://downloads.sourceforge.net/guvcview/guvcview-src-2.1.0.tar.bz2 source = https://downloads.sourceforge.net/guvcview/guvcview-src-2.2.1.tar.bz2
sha256sums = 3d93e4c9fab8d1a7a9bde1a6dbbf04d6cf9d347c134b5128b4586a1d90b63cfb sha256sums = d2adc7ce762961e853c3e16b511bad61504492d12f3e2eb7e30da4a2f7ade5af
pkgname = guvcview pkgname = guvcview
pkgdesc = Simple GTK+ interface for capturing and viewing video from v4l2 devices pkgdesc = Simple GTK+ interface for capturing and viewing video from v4l2 devices
@ -31,4 +31,4 @@ pkgname = guvcview-common
pkgname = guvcview-qt pkgname = guvcview-qt
pkgdesc = Simple Qt interface for capturing and viewing video from v4l2 devices pkgdesc = Simple Qt interface for capturing and viewing video from v4l2 devices
depends = guvcview-common depends = guvcview-common
depends = qt5-base depends = qt6-base

View file

@ -7,67 +7,66 @@
pkgbase=guvcview pkgbase=guvcview
pkgname=(guvcview guvcview-common guvcview-qt) pkgname=(guvcview guvcview-common guvcview-qt)
pkgver=2.1.0 pkgver=2.2.1
pkgrel=5 pkgrel=1
pkgdesc='Simple interface for capturing and viewing video from v4l2 devices' pkgdesc='Simple interface for capturing and viewing video from v4l2 devices'
arch=('x86_64') arch=('x86_64')
url='http://guvcview.sourceforge.net/' url='http://guvcview.sourceforge.net/'
license=('GPL3') license=('GPL3')
depends=('ffmpeg' 'gsl' 'gtk3' 'qt5-base' 'portaudio') depends=('ffmpeg' 'gsl' 'gtk3' 'qt6-base' 'portaudio')
makedepends=('intltool') makedepends=('cmake')
options=('!emptydirs' '!distcc') options=('!emptydirs' '!distcc')
source=("https://downloads.sourceforge.net/$pkgbase/$pkgbase-src-$pkgver.tar.bz2") source=("https://downloads.sourceforge.net/$pkgbase/$pkgbase-src-$pkgver.tar.bz2")
sha256sums=('3d93e4c9fab8d1a7a9bde1a6dbbf04d6cf9d347c134b5128b4586a1d90b63cfb') sha256sums=('d2adc7ce762961e853c3e16b511bad61504492d12f3e2eb7e30da4a2f7ade5af')
noextract=($pkgbase-src-$pkgver-2.tar.bz2) # missing root dir noextract=($pkgbase-src-$pkgver-2.tar.bz2) # missing root dir
prepare() { prepare() {
cp -a $pkgbase{-src-$pkgver,-qt} # Fix appdata install dir
sed -e 's|\/appdata|\/metainfo|' -i $pkgbase-src-$pkgver/data/CMakeLists.txt
} }
build() { build() {
# GTK+ version # GTK+ version
cd $pkgbase-src-$pkgver cmake -B build-gtk -S $pkgbase-src-$pkgver \
./configure --prefix=/usr --disable-debian-menu -DCMAKE_INSTALL_PREFIX=/usr \
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool -DUSE_SFML=ON
make cmake --build build-gtk
# Qt version # Qt version
cd ../$pkgbase-qt cmake -B build-qt -S $pkgbase-src-$pkgver \
./configure --prefix=/usr --disable-debian-menu --disable-gtk3 --enable-qt5 -DCMAKE_INSTALL_PREFIX=/usr \
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool -DUSE_SFML=ON \
make -DUSE_QT6=ON \
-DUSE_GTK3=OFF
cmake --build build-qt
} }
package_guvcview-common() { package_guvcview-common() {
pkgdesc="Common files for guvcview" pkgdesc="Common files for guvcview"
depends=('ffmpeg' 'gsl' 'libusb' 'portaudio') depends=('ffmpeg' 'gsl' 'libusb' 'portaudio')
cd $pkgbase-src-$pkgver DESTDIR="$pkgdir" cmake --install build-gtk
make DESTDIR="$pkgdir" install rm -r "$pkgdir"/usr/{bin,share/{man,metainfo,applications}}
make -C guvcview DESTDIR="$pkgdir" uninstall install -Dm644 $pkgbase-src-$pkgver/data/icons/guvcview.png "$pkgdir"/usr/share/icons/hicolor/128x128/apps/guvcview.png
make -C data DESTDIR="$pkgdir" uninstall-man1 uninstall-appdataDATA uninstall-desktopDATA
install -Dm644 data/icons/guvcview.png "$pkgdir"/usr/share/icons/hicolor/128x128/apps/guvcview.png
} }
package_guvcview() { package_guvcview() {
pkgdesc="Simple GTK+ interface for capturing and viewing video from v4l2 devices" pkgdesc="Simple GTK+ interface for capturing and viewing video from v4l2 devices"
depends=('guvcview-common' 'gtk3') depends=('guvcview-common' 'gtk3')
cd $pkgbase-src-$pkgver DESTDIR="$pkgdir" cmake --install build-gtk
make -C guvcview DESTDIR="$pkgdir" install rm -r "$pkgdir"/usr/{lib,share/{pixmaps,locale}}
make -C data DESTDIR="$pkgdir" install-man1 install-appdataDATA install-desktopDATA
sed -i 's/^Icon=.*/Icon=guvcview/' "$pkgdir"/usr/share/applications/guvcview.desktop sed -i 's/^Icon=.*/Icon=guvcview/' "$pkgdir"/usr/share/applications/guvcview.desktop
} }
package_guvcview-qt() { package_guvcview-qt() {
pkgdesc="Simple Qt interface for capturing and viewing video from v4l2 devices" pkgdesc="Simple Qt interface for capturing and viewing video from v4l2 devices"
depends=('guvcview-common' 'qt5-base') depends=('guvcview-common' 'qt6-base')
cd $pkgbase-qt DESTDIR="$pkgdir" cmake --install build-qt
make -C guvcview DESTDIR="$pkgdir" install rm -r "$pkgdir"/usr/{lib,share/{pixmaps,locale}}
make -C data DESTDIR="$pkgdir" install-man1 install-appdataDATA install-desktopDATA
mv "$pkgdir"/usr/bin/guvcview{,-qt} mv "$pkgdir"/usr/bin/guvcview{,-qt}
mv "$pkgdir"/usr/share/man/man1/guvcview{,-qt}.1 mv "$pkgdir"/usr/share/man/man1/guvcview{,-qt}.1.gz
mv "$pkgdir"/usr/share/applications/guvcview{,-qt}.desktop mv "$pkgdir"/usr/share/applications/guvcview{,-qt}.desktop
sed -i 's/Exec=guvcview/Exec=guvcview-qt/ sed -i 's/Exec=guvcview/Exec=guvcview-qt/
s/^Icon=.*/Icon=guvcview/' "$pkgdir"/usr/share/applications/guvcview-qt.desktop s/^Icon=.*/Icon=guvcview/' "$pkgdir"/usr/share/applications/guvcview-qt.desktop