[arch-commits] Commit in libtraceevent/trunk (2 files)

David Runge dvzrv at gemini.archlinux.org
Mon Dec 20 16:59:45 UTC 2021


    Date: Monday, December 20, 2021 @ 16:59:45
  Author: dvzrv
Revision: 1080391

upgpkg: libtraceevent 1:1.5.0-1: Upgrade to 1.5.0.

Apply patch so that documentation builds work.
Split out documentation to separate docs package.
Simplify quoting in file.

Added:
  libtraceevent/trunk/libtraceevent-1.5.0-documentation.patch
Modified:
  libtraceevent/trunk/PKGBUILD

-----------------------------------------+
 PKGBUILD                                |   55 ++++++++++++++++++++++++------
 libtraceevent-1.5.0-documentation.patch |   12 ++++++
 2 files changed, 56 insertions(+), 11 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-12-20 16:59:25 UTC (rev 1080390)
+++ PKGBUILD	2021-12-20 16:59:45 UTC (rev 1080391)
@@ -1,20 +1,39 @@
 # Maintainer: David Runge <dvzrv at archlinux.org>
 
-pkgname=libtraceevent
-pkgver=1.4.0
+pkgbase=libtraceevent
+pkgname=(libtraceevent libtraceevent-docs)
+pkgver=1.5.0
 pkgrel=1
 epoch=1
 pkgdesc="Linux kernel trace event library"
-arch=('x86_64')
+arch=(x86_64)
 url="https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/about/"
-license=('GPL2' 'LGPL2.1')
-depends=('glibc')
-makedepends=('asciidoc' 'xmlto')
-provides=('libtraceevent.so')
-source=("$pkgname-$pkgver.tar.gz::https://git.kernel.org/pub/scm/libs/libtrace/${pkgname}.git/snapshot/${pkgname}-${pkgver}.tar.gz")
-sha512sums=('7172eccfe382f091f570beaaf9dedc3aa0be4c6cc916ff4b4f8d961d36c88afbb84263cd8fef48d1d6aa0478d45689685195d5ad8596c6e2ad45e0719b62c8eb')
-b2sums=('c12f091c5c6dc14f551c5576efe91f046e4e0320b3542d9d81a5b93910ba074f4a2d465608116cfac90ec6fa85badabcdc0e46f339e682f05810cf7ad52d3639')
+license=(GPL2 LGPL2.1)
+makedepends=(asciidoc xmlto)
+source=(
+  "$pkgname-$pkgver.tar.gz::https://git.kernel.org/pub/scm/libs/libtrace/${pkgname}.git/snapshot/${pkgname}-${pkgver}.tar.gz"
+  "$pkgname-1.5.0-documentation.patch"
+)
+sha512sums=('eb2c57bfcf9039208776b990a55ee6bb6be0396c8b210e2c31f2264f31512dc6c2dbad090b97f567424fe7ab0768ecf443ae28f2e9b21e0f4696c8666460ed76'
+            '74b34a722d3fb9d672826e0b6b137f94a7fcd41bb372f8944bb6a0c652c0e725aaef8e95284fc091c2e9954bcf1656b5428d7e0f121682d40c25623178ee4a1e')
+b2sums=('7f917061e13c04e0e25b144c3e02315e7b91c2ddf3d091643dcd7534d5e7a50b40a68f91bb42b0a6bbe6ebaad9a61cb9de91a809355dfe699ccaadaae5f8e438'
+        'f66f4f20dfe562407a0d4bb53785d1515c4b5f4be64dd96e06ea6c9e03c299b2f0f613901c30893a976b3874d13e768791632a7cb89be92f3788330e4f5ab97d')
 
+_pick() {
+  local p="$1" f d; shift
+  for f; do
+    d="$srcdir/$p/${f#$pkgdir/}"
+    mkdir -p "$(dirname "$d")"
+    mv "$f" "$d"
+    rmdir -p --ignore-fail-on-non-empty "$(dirname "$f")"
+  done
+}
+
+prepare() {
+  cd "$pkgname-$pkgver"
+  patch -Np1 -i ../"$pkgname-1.5.0-documentation.patch"
+}
+
 build() {
   cd "$pkgname-$pkgver"
   make
@@ -21,8 +40,22 @@
   make -C Documentation
 }
 
-package() {
+package_libtraceevent() {
+  depends=(glibc)
+  optdepends=('libtraceevent-docs: for documentation')
+  provides=(libtraceevent.so)
+
   cd "$pkgname-$pkgver"
   make libdir_relative=lib prefix=/usr DESTDIR="$pkgdir/" install
   make libdir_relative=lib prefix=/usr DESTDIR="$pkgdir/" install -C Documentation
+  (
+    cd "${pkgdir}"
+    _pick libtraceevent-docs usr/share/doc
+  )
 }
+
+package_libtraceevent-docs() {
+  pkgdesc+=" - documentation"
+
+  mv -v "${pkgname}/"* "${pkgdir}"
+}

Added: libtraceevent-1.5.0-documentation.patch
===================================================================
--- libtraceevent-1.5.0-documentation.patch	                        (rev 0)
+++ libtraceevent-1.5.0-documentation.patch	2021-12-20 16:59:45 UTC (rev 1080391)
@@ -0,0 +1,12 @@
+diff -ruN a/Documentation/Makefile b/Documentation/Makefile
+--- a/Documentation/Makefile	2021-12-20 03:09:42.000000000 +0100
++++ b/Documentation/Makefile	2021-12-20 16:24:43.651313119 +0100
+@@ -13,8 +13,6 @@
+ _MAN_HTML=$(patsubst %.txt,%.html,$(MAN_TXT))
+ _DOC_MAN3=$(patsubst %.txt,%.m,$(MAN3_TXT))
+ 
+-OUTPUT		:= $(obj)/Documentation/
+-
+ MAN_XML=$(addprefix $(OUTPUT),$(_MAN_XML))
+ MAN_HTML=$(addprefix $(OUTPUT),$(_MAN_HTML))
+ DOC_MAN3=$(addprefix $(OUTPUT),$(_DOC_MAN3))



More information about the arch-commits mailing list