1 # Maintainer: Eduardo Sánchez Muñoz <eduardosanchezmunoz@gmail.com>
6 pkgdesc="A flexible library written in C to parse command line arguments."
8 url="http://code.google.com/p/libreadopt/"
11 makedepends=('gcc' 'mercurial' 'cmake')
13 conflicts=('libreadopt')
14 provides=('libreadopt')
18 _hgroot="https://code.google.com/p"
24 msg "Connecting to Mercurial server...."
26 if [ -d "$_hgrepo" ] ; then
29 msg "The local files are updated."
31 hg clone "$_hgroot/$_hgrepo" "$_hgrepo"
34 msg "Mercurial checkout done or server timeout"
35 msg "Starting make..."
37 rm -rf "$srcdir/$_hgrepo-build"
38 mkdir -p "$srcdir/$_hgrepo-build"
39 cd "$srcdir/$_hgrepo-build"
41 cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr "$srcdir/$_hgrepo/libreadopt"
46 cd "$srcdir/$_hgrepo-build"
47 make DESTDIR="$pkgdir" install