diff options
Diffstat (limited to 'community/openthreads/PKGBUILD')
-rw-r--r-- | community/openthreads/PKGBUILD | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/community/openthreads/PKGBUILD b/community/openthreads/PKGBUILD new file mode 100644 index 000000000..ff94915c2 --- /dev/null +++ b/community/openthreads/PKGBUILD @@ -0,0 +1,36 @@ +# $Id: PKGBUILD 66257 2012-02-23 05:29:45Z spupykin $ +# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com> +# Contributor: William Rea <sillywilly@gmail.com> + +pkgname=openthreads +pkgver=2.3.0 +pkgrel=2 +pkgdesc="A minimal & complete Object-Oriented thread interface for C++ programmers" +arch=('i686' 'x86_64') +url="http://openthreads.sourceforge.net" +license=("LGPL") +depends=('gcc-libs') +makedepends=('cmake') +source=(http://www.openscenegraph.org/downloads/developer_releases/OpenThreads-$pkgver.zip) +md5sums=('ab4899c9d11e3917bd5f1401d6d0af11') + +build() { + cd "$srcdir/OpenThreads-$pkgver" + + sed -i 's#-lpthreads#-lpthread#' CMakeModules/FindThreads.cmake + sed -i 's#SET(CMAKE_REQUIRED_LIBRARIES "${CMAKE_REQUIRED_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT}")#SET(CMAKE_REQUIRED_LIBRARIES "${CMAKE_THREAD_LIBS_INIT}")#' src/OpenThreads/pthreads/CMakeLists.txt + + cmake . -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_PREFIX=/usr + + make +} + +package() { + cd "$srcdir/OpenThreads-$pkgver" + + sed -i 's#lib64#lib#' src/OpenThreads/pthreads/cmake_install.cmake + make DESTDIR="$pkgdir" install + + install -D packaging/pkg_config/openthreads.pc ${pkgdir}/usr/lib/pkgconfig/openthreads.pc +} |