1 # Maintainer: David Runge <dvzrv@archlinux.org>
2 # Contributor: Laurent Carlier <lordheavym@gmail.com>
3 # Contributor: Stéphane Gaudreault <stephane@archlinux.org>
4 # Contributor: Andrej Gelenberg <andrej.gelenberg@udo.edu>
7 pkgname=('debuginfod' 'elfutils' 'libelf')
10 pkgdesc='Handle ELF object files and DWARF debugging information'
12 url="https://sourceware.org/elfutils/"
13 license=('LGPL3' 'GPL3')
14 makedepends=('bzip2' 'curl' 'gcc-libs' 'libarchive' 'libmicrohttpd' 'sqlite'
16 options=('staticlibs')
17 source=("https://sourceware.org/${pkgbase}/ftp/${pkgver}/${pkgbase}-${pkgver}.tar.bz2"{,.sig})
18 sha512sums=('c9180b27ec62935f18b9431268d176f6023d1bb938731d2af6e7626ae460af6608a70ba68483aa1ec7e6cb0fa0528b661ca8b68bc4f58ea8e18af527c5950c78'
20 b2sums=('49573d0a1f3519eab81d1ba3e94354cbc0935a36a94a3fdb22fe223a47b78cca8fd6e322870b0e335a809529fa6f54180b13c67936dec0242123c54ba20c9fc9'
23 '47CC0331081B8BC6D0FD4DA08370665B57816A6A' # Mark J. Wielaard <mark@klomp.org>
24 'EC3CFE88F6CA0788774F5C1D1AA44BE649DE760A' # Mark Wielaard <mjw@gnu.org>
33 cp -av "$pkgbase-$pkgver" "$pkgbase-test-$pkgver"
40 ./configure --prefix=/usr \
42 --program-prefix="eu-" \
43 --enable-deterministic-archives
47 cd "$pkgbase-test-$pkgver"
48 CFLAGS+=" -g" # required for test-suite success
49 ./configure --prefix=/usr \
51 --program-prefix="eu-" \
52 --enable-deterministic-archives
58 cd "$pkgbase-test-$pkgver"
63 pkgdesc+=" (libraries)"
64 depends=('gcc-libs' 'libbz2.so' 'libcurl.so' 'xz' 'zlib' 'zstd')
65 # NOTE: the shared objects can not be added to provides as they are not versioned
68 make DESTDIR="$pkgdir" install
69 # remove files provided by elfutils or debuginfod
70 rm -rvf "${pkgdir}"{/etc,/usr/{bin,share}}
71 install -vDm 644 {AUTHORS,ChangeLog,NEWS,NOTES,README} \
72 -t "${pkgdir}/usr/share/doc/${pkgname}"
76 pkgdesc+=" (utilities)"
77 depends=('gcc-libs' 'glibc' "libelf=${pkgver}-${pkgrel}")
80 make DESTDIR="$pkgdir" install
81 install -vDm 644 {AUTHORS,ChangeLog,NEWS,NOTES,README} \
82 -t "${pkgdir}/usr/share/doc/${pkgname}"
83 # remove files provided by libelf
84 rm -rvf "${pkgdir}/usr/"{include,lib}
85 # remove files provided by debuginfod
86 rm -rvf "${pkgdir}/usr/bin/debuginfod"* \
87 "${pkgdir}/usr/share/man/man1/debuginfod"* \
88 "${pkgdir}/usr/share/man/man3/debuginfod"* \
89 "${pkgdir}/usr/share/man/man7/" \
90 "${pkgdir}/usr/share/man/man8/" \
94 package_debuginfod() {
95 pkgdesc+=" (debuginfod)"
96 depends=('gcc-libs' 'glibc' 'libarchive.so' "libelf=${pkgver}-${pkgrel}"
97 'libmicrohttpd.so' 'sqlite')
98 optdepends=("elfutils=${pkgver}-${pkgrel}: for translations" )
100 cd "$pkgbase-$pkgver"
101 make DESTDIR="$pkgdir" install
102 install -vDm 644 {AUTHORS,ChangeLog,NEWS,NOTES,README} \
103 -t "${pkgdir}/usr/share/doc/${pkgname}"
104 # remove files provided by libelf
105 rm -rvf "${pkgdir}/usr/"{include,lib}
106 # remove files provided by elfutils
107 rm -rvf "${pkgdir}/usr/bin/eu-"* \
108 "${pkgdir}/usr/share/man/man1/eu-"* \
109 "${pkgdir}/usr/share/man/man3/elf_"* \
110 "${pkgdir}/usr/share/locale"