[arch-commits] Commit in libvterm01/trunk (PKGBUILD libvterm01-0.1.4-pkgconf.patch)

David Runge dvzrv at gemini.archlinux.org
Mon Apr 18 12:37:48 UTC 2022


    Date: Monday, April 18, 2022 @ 12:37:48
  Author: dvzrv
Revision: 1186977

upgpkg: libvterm01 0.1.4-2: Rebuild to move library to private location.

The package should not conflict with libvterm, so move its headers and libs to private location.
Add patch to fix the include directory exposed by pkgconfig.
Add debug package.

Added:
  libvterm01/trunk/libvterm01-0.1.4-pkgconf.patch
Modified:
  libvterm01/trunk/PKGBUILD

--------------------------------+
 PKGBUILD                       |   28 ++++++++++++++++++----------
 libvterm01-0.1.4-pkgconf.patch |   23 +++++++++++++++++++++++
 2 files changed, 41 insertions(+), 10 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2022-04-18 10:51:09 UTC (rev 1186976)
+++ PKGBUILD	2022-04-18 12:37:48 UTC (rev 1186977)
@@ -1,28 +1,36 @@
 # Maintainer: Sven-Hendrik Haase <svenstaro at archlinux.org>
 # Contributor: Florian Walch <florian+aur at fwalch.com>
 
+_name=libvterm
 pkgname=libvterm01
 pkgver=0.1.4
-pkgrel=1
+pkgrel=2
 pkgdesc='Abstract library implementation of a VT220/xterm/ECMA-48 terminal emulator'
 arch=('x86_64')
 url='https://www.leonerd.org.uk/code/libvterm/'
 license=('MIT')
 depends=('glibc')
-provides=('libvterm')
-conflicts=('libvterm')
-source=("https://www.leonerd.org.uk/code/libvterm/libvterm-${pkgver}.tar.gz")
-sha256sums=('bc70349e95559c667672fc8c55b9527d9db9ada0fb80a3beda533418d782d3dd')
+options=(debug)
+source=(
+  "https://www.leonerd.org.uk/code/libvterm/libvterm-${pkgver}.tar.gz"
+  $pkgname-0.1.4-pkgconf.patch
+)
+sha256sums=('bc70349e95559c667672fc8c55b9527d9db9ada0fb80a3beda533418d782d3dd'
+            'b07067c0d505607a5b2cfa55c2947b859187346b32931fd881c9690aa4ced6d7')
 
+prepare() {
+  patch -Np1 -d $_name-$pkgver -i ../$pkgname-0.1.4-pkgconf.patch
+}
+
 build() {
-  cd "libvterm-${pkgver}"
-  make PREFIX=/usr
+  make -C $_name-$pkgver
 }
 
 package() {
-  cd "libvterm-${pkgver}"
-  make PREFIX=/usr DESTDIR="${pkgdir}" install
-  install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+  make INCDIR=/usr/include/$pkgname LIBDIR=/usr/lib/$pkgname PREFIX=/usr DESTDIR="$pkgdir" install -C $_name-$pkgver
+  rm -frv "$pkgdir/usr/"{bin,share}
+
+  install -Dm644 $_name-$pkgver/LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/"
 }
 
 # vim:set sw=2 sts=2 et:

Added: libvterm01-0.1.4-pkgconf.patch
===================================================================
--- libvterm01-0.1.4-pkgconf.patch	                        (rev 0)
+++ libvterm01-0.1.4-pkgconf.patch	2022-04-18 12:37:48 UTC (rev 1186977)
@@ -0,0 +1,23 @@
+diff -ruN a/Makefile b/Makefile
+--- a/Makefile	2020-08-22 16:54:34.000000000 +0200
++++ b/Makefile	2022-04-18 12:53:36.830425742 +0200
+@@ -97,7 +97,7 @@
+ 	install -d $(DESTDIR)$(INCDIR)
+ 	install -m644 $(HFILES) $(DESTDIR)$(INCDIR)
+ 	install -d $(DESTDIR)$(LIBDIR)/pkgconfig
+-	sed -e "s, at PREFIX@,$(PREFIX)," -e "s, at LIBDIR@,$(LIBDIR)," -e "s, at VERSION@,$(VERSION)," <vterm.pc.in >$(DESTDIR)$(LIBDIR)/pkgconfig/vterm.pc
++	sed -e "s, at PREFIX@,$(PREFIX)," -e "s, at INCDIR@,$(INCDIR)," -e "s, at LIBDIR@,$(LIBDIR)," -e "s, at VERSION@,$(VERSION)," <vterm.pc.in >$(DESTDIR)$(LIBDIR)/pkgconfig/vterm.pc
+ 
+ install-lib: $(LIBRARY)
+ 	install -d $(DESTDIR)$(LIBDIR)
+diff -ruN a/vterm.pc.in b/vterm.pc.in
+--- a/vterm.pc.in	2020-08-22 16:54:34.000000000 +0200
++++ b/vterm.pc.in	2022-04-18 12:52:28.900128681 +0200
+@@ -1,6 +1,6 @@
+ prefix=@PREFIX@
+ libdir=@LIBDIR@
+-includedir=${prefix}/include
++includedir=@INCDIR@
+ 
+ Name: vterm
+ Description: Abstract VT220/Xterm/ECMA-48 emulation library



More information about the arch-commits mailing list