summaryrefslogtreecommitdiff
path: root/argtable/PKGBUILD
blob: 8fed3a1abf3d4d732074692a8984ac03b290abee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Maintainer:  Erich Eckner <arch at eckner dot net>
# Contributor: TDY <tdy@archlinux.info>
# Contributor: Mark Taylor <skymt0 at gmail dot com>

pkgbase=argtable
pkgname=('argtable' 'argtable-docs')
pkgver=2.13
pkgrel=2
pkgdesc="An ANSI C command line parser"
arch=('i686' 'pentium4' 'x86_64')
# argtable-docs ist absichtlich nicht any ohne ELF Dateien
url="http://argtable.sourceforge.net/"
license=('GPL')
source=("https://sourceforge.net/projects/$pkgname/files/$pkgname/$pkgname-$pkgver/$pkgname${pkgver/./-}.tar.gz")
sha512sums=('3d8303f3ba529e3241d918c0127a16402ece951efb964d14a06a3a7d29a252812ad3c44e96da28798871e9923e73a2cfe7ebc84139c1397817d632cae25c4585')
makedepends=('glibc')

build() {
  cd "$srcdir/${pkgname%-*}${pkgver/./-}"
  ./configure --prefix=/usr
  make
}

check_argtable() {
  cd "$srcdir/${pkgname%-*}${pkgver/./-}"
  make -k check
}

package_argtable() {
  _pinned_dependencies=(
    'glibc>=2.31'
  )
  depends=("${_pinned_dependencies[@]}")
  options=('!libtool')

  cd "$srcdir/${pkgname%-*}${pkgver/./-}"
  sed -i '/^install-data-am:/s/install-dist_exampleDATA //' Makefile
  make SUBDIRS="src tests" DESTDIR="$pkgdir/" install
}

package_argtable-docs() {
  pkgdesc="Documentation and examples for argtable"
  unset _pinned_dependencies

  cd "$srcdir/${pkgname%-*}${pkgver/./-}"
  make -C doc DESTDIR="$pkgdir/" install
  make DESTDIR="$pkgdir/" install-dist_exampleDATA
}

# vim:set ts=2 sw=2 et: