diff options
author | Michel Zou | 2019-12-10 21:31:25 +0100 |
---|---|---|
committer | Michel Zou | 2019-12-10 21:31:25 +0100 |
commit | 7d4bc6e433b96774cbf8c736474c2922a6f266d0 (patch) | |
tree | 9769226ea1c37f93175cb0fb603c38a4b9fb0adf | |
download | aur-7d4bc6e433b96774cbf8c736474c2922a6f266d0.tar.gz |
2.4.2
-rw-r--r-- | .SRCINFO | 17 | ||||
-rw-r--r-- | PKGBUILD | 42 |
2 files changed, 59 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..28207145594a --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,17 @@ +pkgbase = mingw-w64-libbatch + pkgdesc = Generic platform for Pre and Post-Processing for numerical simulation - KERNEL Module + pkgver = 2.4.2 + pkgrel = 1 + url = http://www.salome-platform.org + arch = any + license = LGPL + makedepends = mingw-w64-cmake + depends = mingw-w64-python + options = !buildflags + options = !strip + options = staticlibs + source = libbatch-2.4.2::git+git://git.salome-platform.org/tools/libbatch.git#tag=V2_4_2 + sha256sums = SKIP + +pkgname = mingw-w64-libbatch + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..df992c59b18e --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,42 @@ +pkgname=mingw-w64-libbatch +pkgver=2.4.2 +pkgrel=1 +pkgdesc="Generic platform for Pre and Post-Processing for numerical simulation - KERNEL Module" +url="http://www.salome-platform.org" +depends=('mingw-w64-python') +makedepends=('mingw-w64-cmake') +options=('!buildflags' '!strip' 'staticlibs') +arch=('any') +license=('LGPL') +source=("libbatch-${pkgver}::git+git://git.salome-platform.org/tools/libbatch.git#tag=V${pkgver//./_}") +sha256sums=('SKIP') +_architectures="i686-w64-mingw32 x86_64-w64-mingw32" + +prepare () { + cd "$srcdir/libbatch-${pkgver}" + sed -i "s|ADD_DEFINITIONS(/wd4251|#|g" src/CMakeLists.txt + sed -i "s|Windows.h|windows.h|g" src/Local/BatchManager_Local.hxx src/Core/Utils.cxx +} + +build() { + cd "$srcdir/libbatch-${pkgver}" + for _arch in ${_architectures}; do + mkdir -p build-${_arch} && pushd build-${_arch} + ${_arch}-cmake-py38 \ + -DPTHREAD_LIBRARY=/usr/${_arch}/lib/libwinpthread.dll.a \ + .. + make + popd + done +} + +package() { + for _arch in ${_architectures}; do + cd "$srcdir/libbatch-${pkgver}/build-${_arch}" + make install DESTDIR="$pkgdir" + install -d "$pkgdir"/usr/${_arch}/bin + mv "$pkgdir"/usr/${_arch}/lib/*.dll "$pkgdir"/usr/${_arch}/bin + ${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll + ${_arch}-strip -g "$pkgdir"/usr/${_arch}/lib/*.a + done +} |