Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add gts (version 0.7.6) * gts: simplify build() function * gts: separate lines for readability * gts: remove redundant line
- Loading branch information
Showing
2 changed files
with
61 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Maintainer: Andrew Sun <adsun701@gmail.com> | ||
|
||
_realname=gts | ||
pkgbase=mingw-w64-${_realname} | ||
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}") | ||
pkgver=0.7.6 | ||
pkgrel=1 | ||
pkgdesc="Provides useful functions to deal with 3D surfaces meshed with interconnected triangles (mingw-w64)" | ||
arch=('any') | ||
url="http://gts.sourceforge.net/" | ||
license=('LGPL') | ||
depends=("${MINGW_PACKAGE_PREFIX}-glib2") | ||
source=("https://downloads.sourceforge.net/project/${_realname}/${_realname}/${pkgver}/${_realname}-${pkgver}.tar.gz" | ||
"gts-mingw.patch") | ||
sha256sums=('059c3e13e3e3b796d775ec9f96abdce8f2b3b5144df8514eda0cc12e13e8b81e' | ||
'7efb4a8e76dbb9b18bd35b7021ed269d8d5c871b3acd22367c4febf27d67fed7') | ||
|
||
prepare() { | ||
cd "${srcdir}/${_realname}-${pkgver}" | ||
patch -Np1 -i "${srcdir}/gts-mingw.patch" | ||
WANT_AUTOMAKE=latest autoreconf -fiv | ||
} | ||
|
||
build() { | ||
[[ -d "${srcdir}"/build-${CARCH} ]] && rm -rf "${srcdir}"/build-${CARCH} | ||
cp -rf "${srcdir}"/${_realname}-${pkgver}/. "${srcdir}"/build-${CARCH} | ||
cd "${srcdir}"/build-${CARCH} | ||
|
||
export LDFLAGS=${LDFLAGS//--as-needed,} | ||
./configure \ | ||
--prefix=${MINGW_PREFIX} \ | ||
--build=${MINGW_CHOST} \ | ||
--host=${MINGW_CHOST} \ | ||
--target=${MINGW_CHOST} \ | ||
--enable-static \ | ||
--enable-shared | ||
|
||
make | ||
} | ||
|
||
package() { | ||
cd "${srcdir}"/build-${CARCH} | ||
make install DESTDIR="${pkgdir}" | ||
|
||
local PREFIX_WIN=$(cygpath -wm ${MINGW_PREFIX}) | ||
sed -e "s|${PREFIX_WIN}|${MINGW_PREFIX}|g" -i "${pkgdir}${MINGW_PREFIX}/bin/gts-config" | ||
|
||
install -Dm644 ${srcdir}/${_realname}-${pkgver}/COPYING ${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/COPYING | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
diff -Naur gts-0.7.6.orig/src/Makefile.am gts-0.7.6/src/Makefile.am | ||
--- gts-0.7.6.orig/src/Makefile.am 2018-06-15 07:53:09.209430583 -0400 | ||
+++ gts-0.7.6/src/Makefile.am 2018-06-15 07:57:00.839780556 -0400 | ||
@@ -13,7 +13,7 @@ | ||
lib_LTLIBRARIES = libgts.la | ||
|
||
libgts_la_LDFLAGS = -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)\ | ||
- -release $(LT_RELEASE) -export-dynamic | ||
+ -release $(LT_RELEASE) -export-dynamic -no-undefined | ||
|
||
libgts_la_DEPENDENCIES = \ | ||
predicates_init.h |