[arch-commits] Commit in gdb/repos (staging-x86_64 staging-x86_64/PKGBUILD)

Bartłomiej Piotrowski bpiotrowski at archlinux.org
Sun May 10 16:19:37 UTC 2020


    Date: Sunday, May 10, 2020 @ 16:19:36
  Author: bpiotrowski
Revision: 383111

archrelease: copy trunk to staging-x86_64

Added:
  gdb/repos/staging-x86_64/
  gdb/repos/staging-x86_64/PKGBUILD
    (from rev 383110, gdb/trunk/PKGBUILD)

----------+
 PKGBUILD |   84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 84 insertions(+)

Copied: gdb/repos/staging-x86_64/PKGBUILD (from rev 383110, gdb/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD	                        (rev 0)
+++ staging-x86_64/PKGBUILD	2020-05-10 16:19:36 UTC (rev 383111)
@@ -0,0 +1,84 @@
+# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
+# Maintainer: Anatol Pomozov <anatol.pomozov at gmail.com>
+# Contributor: Allan McRae <allan at archlinux.org>
+# Contributor: Jan de Groot <jgc at archlinux.org>
+
+pkgbase=gdb
+# gdb-common is a package that contains files common for all cross compiled versions
+# of gdb (for arm/avr/...)
+pkgname=(gdb gdb-common)
+pkgver=9.1
+pkgrel=3
+pkgdesc='The GNU Debugger'
+arch=(x86_64)
+url='https://www.gnu.org/software/gdb/'
+license=(GPL3)
+makedepends=(texinfo python guile2.0 ncurses expat xz mpfr source-highlight)
+source=(https://ftp.gnu.org/gnu/gdb/${pkgname}-${pkgver}.tar.xz{,.sig})
+sha1sums=('a50e13e1eecea468ea28c4a23d8c5a84f4db25be'
+          'SKIP')
+b2sums=('b84b1dc627d7ba697dfd76ba7c0f4f88f1725e1e1b83134d08cf53bf867ebfa07e1d01eff2acd9a57d22a779077bf6ed95d6098e8a58c4d86eaed034ca62ac30'
+        'SKIP')
+validpgpkeys=('F40ADB902B24264AA42E50BF92EDB04BFF325CF3') # Joel Brobecker
+
+prepare() {
+  cd gdb-$pkgver
+
+  # hack! - libiberty configure tests for header files using "$CPP $CPPFLAGS"
+  sed -i "/ac_cpp=/s/\$CPPFLAGS/\$CPPFLAGS -O2/" libiberty/configure
+}
+
+build() {
+  cd gdb-$pkgver
+
+  mkdir -p build && cd build
+  ../configure \
+    --prefix=/usr \
+    --disable-nls \
+    --enable-source-highlight \
+    --enable-tui \
+    --with-system-readline \
+    --with-python=/usr/bin/python \
+    --with-guile=guile-2.0 \
+    --with-system-gdbinit=/etc/gdb/gdbinit
+  make
+}
+
+package_gdb-common() {
+  depends=(python guile2.0)
+
+  cd gdb-$pkgver/build
+
+  make DESTDIR="$pkgdir" install
+  # resolve conflicts with binutils
+  rm "$pkgdir"/usr/include/{ansidecl,bfd,bfdlink,dis-asm,plugin-api,symcat,ctf,ctf-api,bfd_stdint,diagnostics}.h
+  rm "$pkgdir"/usr/share/info/bfd.info
+  rm "$pkgdir"/usr/lib/{libbfd,libopcodes,libctf,libctf-nobfd}.a
+
+  rm -r "$pkgdir"/usr/{bin,include,lib,share/info,share/man}
+}
+
+package_gdb() {
+  depends=(ncurses expat xz mpfr source-highlight gdb-common=$pkgver)
+  backup=(etc/gdb/gdbinit)
+
+  cd gdb-$pkgver/build
+  make DESTDIR="$pkgdir" install
+
+  # resolve conflicts with binutils
+  rm "$pkgdir"/usr/include/{ansidecl,bfd,bfdlink,dis-asm,plugin-api,symcat,ctf,ctf-api,bfd_stdint,diagnostics}.h
+  rm "$pkgdir"/usr/share/info/bfd.info
+  rm "$pkgdir"/usr/lib/{libbfd,libopcodes,libctf,libctf-nobfd}.a
+  rm "$pkgdir"/usr/lib/libinproctrace.so*
+  rm "$pkgdir"/usr/bin/gdbserver
+
+
+  # install "custom" system gdbinit
+  install -dm 755 "$pkgdir/etc/gdb"
+  touch "$pkgdir/etc/gdb/gdbinit"
+
+  # comes from gdb-common
+  rm -r "$pkgdir/usr/share/gdb/"
+}
+
+# vim: ts=2 sw=2 et:


More information about the arch-commits mailing list