diff options
author | Daniel Bermond | 2017-02-26 20:21:24 -0300 |
---|---|---|
committer | Daniel Bermond | 2017-02-26 20:21:24 -0300 |
commit | 123d7dc15fa6957d6c3f4a1ef021f442f8e04c3e (patch) | |
tree | 9a0941a787e4b2e559a8658086135601d37ea3d4 | |
download | aur-123d7dc15fa6957d6c3f4a1ef021f442f8e04c3e.tar.gz |
Initial commit
-rw-r--r-- | .SRCINFO | 16 | ||||
-rw-r--r-- | PKGBUILD | 44 |
2 files changed, 60 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..b09dfc7d63c7 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,16 @@ +# Generated by mksrcinfo v8 +# Sun Feb 26 23:20:58 UTC 2017 +pkgbase = trio + pkgdesc = Portable string functions, focus on the *printf() and *scanf() clones + pkgver = 1.16 + pkgrel = 1 + url = https://sourceforge.net/projects/ctrio/ + arch = i686 + arch = x86_64 + license = custom + provides = libtrio.so + source = http://downloads.sourceforge.net/project/ctrio/trio/trio-1.16.tar.gz + sha256sums = 84d0e74f5b25f0b6c7d9b264ef41f98908e65a5056d4e75c5ef0e05d6a69fc0a + +pkgname = trio + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..dee21541519f --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,44 @@ +# Maintainer: Daniel Bermond < yahoo-com: danielbermond > + +pkgname=trio +pkgver=1.16 +pkgrel=1 +pkgdesc="Portable string functions, focus on the *printf() and *scanf() clones" +arch=('i686' 'x86_64') +url="https://sourceforge.net/projects/ctrio/" +license=('custom') +provides=('libtrio.so') +source=("http://downloads.sourceforge.net/project/ctrio/${pkgname}/${pkgname}-${pkgver}.tar.gz") +sha256sums=('84d0e74f5b25f0b6c7d9b264ef41f98908e65a5056d4e75c5ef0e05d6a69fc0a') + +build() { + cd "$pkgname"-"$pkgver" + ./autogen.sh + ./configure --prefix=/usr + + # add correct installation directories to Makefile + sed -i '21iDESTDIR = ' Makefile + sed -i '25s/\${prefix}/\${DESTDIR}\/\${prefix}/' Makefile + sed -i '26s/\${prefix}\/include/\${DESTDIR}\/\${prefix}\/include/' Makefile + + make +} + +package() { + cd "$pkgname"-"$pkgver" + make DESTDIR="$pkgdir/" install + install -D -m644 README "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + + # get library major, minor and micro version numbers + local _major_ver="$(printf libtrio.so.*.*.* | sed 's/libtrio\.so\.//;s/\.[0-9]*\.[0-9]*$//')" + local _minor_ver="$(printf libtrio.so.*.*.* | sed 's/libtrio\.so\.//;s/^[0-9]*\.//;s/\.[0-9]*$//')" + local _micro_ver="$(printf libtrio.so.*.*.* | sed 's/libtrio\.so\.//;s/^[0-9]*\.[0-9]*\.//')" + + # create missing library symbolic links + ln -sf "libtrio.so.${_major_ver}.${_minor_ver}.${_micro_ver}" "libtrio.so.${_major_ver}" + ln -sf "libtrio.so.${_major_ver}.${_minor_ver}.${_micro_ver}" "libtrio.so" + + # copy missing library symbolic links to installation directory + cp -a "libtrio.so.${_major_ver}" "${pkgdir}/usr/lib" + cp -a "libtrio.so" "${pkgdir}/usr/lib" +} |