diff options
author | Martchus | 2023-04-29 18:15:40 +0200 |
---|---|---|
committer | Marius Kittler | 2023-04-29 18:17:41 +0200 |
commit | fbc5f58e5b03827ee64e4930b334083d08e0758d (patch) | |
tree | 0dbe6b49710922c21d18629030ba63f42b8ad4b1 | |
parent | 47d03bf03baf0a2c2883d3030be331922751fe88 (diff) | |
download | aur-fbc5f58e5b03827ee64e4930b334083d08e0758d.tar.gz |
Fix include directory and various details
-rw-r--r-- | .SRCINFO | 10 | ||||
-rw-r--r-- | 66685a74bb55d82a97c6ae46b7cd91152bbbfffd.patch | 30 | ||||
-rw-r--r-- | PKGBUILD | 26 |
3 files changed, 54 insertions, 12 deletions
@@ -1,16 +1,20 @@ pkgbase = pocketsphinx pkgdesc = A small speech recognizer pkgver = 5.0.0 - pkgrel = 1 + pkgrel = 2 url = https://cmusphinx.github.io arch = i686 arch = x86_64 - license = custom + license = BSD + license = MIT makedepends = cmake makedepends = ninja makedepends = gst-plugins-base-libs optdepends = gst-plugins-base-libs: GStreamer plugin - source = https://github.com/cmusphinx/pocketsphinx/archive/refs/tags/v5.0.0.tar.gz + source = pocketsphinx-5.0.0.tar.gz::https://github.com/cmusphinx/pocketsphinx/archive/refs/tags/v5.0.0.tar.gz + source = 66685a74bb55d82a97c6ae46b7cd91152bbbfffd.patch sha256sums = 78ffe5b60b6981b08667435dd26c5a179b612b8ca372bd9c23c896a8b2239a20 + sha256sums = 428fc297f047ea95fe24f7e43b723cdfdb7215de518455e939ef86ff1aa10af6 pkgname = pocketsphinx + diff --git a/66685a74bb55d82a97c6ae46b7cd91152bbbfffd.patch b/66685a74bb55d82a97c6ae46b7cd91152bbbfffd.patch new file mode 100644 index 000000000000..f7343fae92d3 --- /dev/null +++ b/66685a74bb55d82a97c6ae46b7cd91152bbbfffd.patch @@ -0,0 +1,30 @@ +From 66685a74bb55d82a97c6ae46b7cd91152bbbfffd Mon Sep 17 00:00:00 2001 +From: Sam Ford <1584702+samford@users.noreply.github.com> +Date: Thu, 16 Feb 2023 15:11:10 -0500 +Subject: [PATCH] fix: use trailing slash with include directory + +`CMakeLists.txt` references the `include` directory without a trailing +slash, which can cause related files to be installed to +`include/include` (e.g., in Homebrew). Using `include/` ensures the +files will be installed to `include`, as expected. + +Co-authored-by: Carlo Cabrera <30379873+carlocab@users.noreply.github.com> +--- + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 64b0c53be..09501c82c 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -108,8 +108,8 @@ else() + endif() + configure_file(pocketsphinx.pc.in pocketsphinx.pc @ONLY) + install(TARGETS pocketsphinx LIBRARY) +- install(DIRECTORY include TYPE INCLUDE) +- install(DIRECTORY ${CMAKE_BINARY_DIR}/include TYPE INCLUDE) ++ install(DIRECTORY include/ TYPE INCLUDE) ++ install(DIRECTORY ${CMAKE_BINARY_DIR}/include/ TYPE INCLUDE) + install(FILES ${CMAKE_BINARY_DIR}/pocketsphinx.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + + option(BUILD_GSTREAMER "Build GStreamer plugin" OFF) @@ -1,31 +1,39 @@ # Maintainer: Martchus <martchus@gmx.net> +# Contributor: éclairevoyant # Contributor: Marco Pompili <aur AT emarcs DOT org> # Contributor: Ben Duffield <bavardage AT archlinux.us> pkgname=pocketsphinx pkgver=5.0.0 -pkgrel=1 +pkgrel=2 pkgdesc='A small speech recognizer' arch=('i686' 'x86_64') url='https://cmusphinx.github.io' -license=('custom') +license=('BSD' 'MIT') makedepends=('cmake' 'ninja' 'gst-plugins-base-libs') optdepends=('gst-plugins-base-libs: GStreamer plugin') -source=("https://github.com/cmusphinx/pocketsphinx/archive/refs/tags/v$pkgver.tar.gz") -sha256sums=('78ffe5b60b6981b08667435dd26c5a179b612b8ca372bd9c23c896a8b2239a20') +source=("$pkgname-$pkgver.tar.gz::https://github.com/cmusphinx/pocketsphinx/archive/refs/tags/v$pkgver.tar.gz" + '66685a74bb55d82a97c6ae46b7cd91152bbbfffd.patch') +sha256sums=('78ffe5b60b6981b08667435dd26c5a179b612b8ca372bd9c23c896a8b2239a20' + '428fc297f047ea95fe24f7e43b723cdfdb7215de518455e939ef86ff1aa10af6') + +prepare() { + cd $pkgname-$pkgver + + patch -p1 -i ../66685a74bb55d82a97c6ae46b7cd91152bbbfffd.patch +} build() { - cd "$pkgname-$pkgver" + cd $pkgname-$pkgver cmake -S . -B build -DCMAKE_INSTALL_PREFIX=/usr -DBUILD_SHARED_LIBS=ON -DBUILD_GSTREAMER=ON cmake --build build } package() { - cd "$pkgname-$pkgver" + cd $pkgname-$pkgver - DESTDIR=${pkgdir} cmake --build build --target install + DESTDIR="$pkgdir" cmake --install build - install -d -m755 "${pkgdir}/usr/share/licenses/${pkgname}" - install -D -m644 "${srcdir}/${pkgname}-${pkgver}/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" + install -D -m644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/" } |