summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorbrainpower2015-01-12 22:31:54 +0100
committerbrainpower2015-01-12 22:31:54 +0100
commitcb374bd230e26773ef968b914c911ad6d4849355 (patch)
treea4754183cdfa4da16f3e6ff79bd3ddc510f5ad10
downloadaur-cb374bd230e26773ef968b914c911ad6d4849355.tar.gz
add sfml-git PKGBUILD
-rw-r--r--.SRCINFO29
-rw-r--r--0001-fix_cmake_module_install_path.patch12
-rw-r--r--PKGBUILD52
-rw-r--r--sfml-git.install3
4 files changed, 96 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..20fbbb38a77
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,29 @@
+pkgbase = sfml-git
+ pkgdesc = A simple, fast, cross-platform, and object-oriented multimedia API
+ pkgver = 2.2.r22.gc303d1f
+ pkgrel = 1
+ url = http://www.sfml-dev.org/
+ arch = i686
+ arch = x86_64
+ license = zlib
+ makedepends = mesa
+ makedepends = cmake
+ makedepends = doxygen
+ makedepends = git
+ depends = libsndfile
+ depends = libxrandr
+ depends = libjpeg
+ depends = openal
+ depends = glew
+ depends = freetype2
+ provides = sfml
+ conflicts = sfml
+ replaces = sfml
+ options = debug
+ source = git+https://github.com/LaurentGomila/SFML.git
+ source = 0001-fix_cmake_module_install_path.patch
+ sha256sums = SKIP
+ sha256sums = c0be2636b1d342f636f2587e043dbfa8becdd8d9c65044cf7749ab4b2c81eb47
+
+pkgname = sfml-git
+
diff --git a/0001-fix_cmake_module_install_path.patch b/0001-fix_cmake_module_install_path.patch
new file mode 100644
index 00000000000..f8bbaa021ae
--- /dev/null
+++ b/0001-fix_cmake_module_install_path.patch
@@ -0,0 +1,12 @@
+--- CMakeLists.txt.orig 2015-01-12 21:34:37.788280159 +0100
++++ CMakeLists.txt 2015-01-12 21:36:44.646681413 +0100
+@@ -242,7 +242,8 @@
+ install(FILES license.txt DESTINATION ${INSTALL_MISC_DIR})
+ install(FILES readme.txt DESTINATION ${INSTALL_MISC_DIR})
+ if(NOT SFML_OS_ANDROID)
+- install(FILES cmake/Modules/FindSFML.cmake DESTINATION ${INSTALL_MISC_DIR}/cmake/Modules)
++ set(CM_VER ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION})
++ install(FILES cmake/Modules/FindSFML.cmake DESTINATION share/cmake-${CM_VER}/Modules)
+ endif()
+
+ # install 3rd-party libraries and tools
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..a5532ab9b65
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,52 @@
+# Maintainer: oi_wtf <brainpower at gulli dot com>
+
+pkgname=sfml-git
+pkgver=2.2.r22.gc303d1f
+pkgrel=1
+pkgdesc="A simple, fast, cross-platform, and object-oriented multimedia API"
+arch=('i686' 'x86_64')
+url="http://www.sfml-dev.org/"
+license=('zlib')
+depends=('libsndfile' 'libxrandr' 'libjpeg' 'openal' 'glew' 'freetype2')
+makedepends=('mesa' 'cmake' 'doxygen' 'git')
+provides=('sfml')
+conflicts=('sfml')
+replaces=('sfml')
+options=('debug')
+
+source=("git+https://github.com/LaurentGomila/SFML.git"
+ "0001-fix_cmake_module_install_path.patch")
+sha256sums=('SKIP'
+ 'c0be2636b1d342f636f2587e043dbfa8becdd8d9c65044cf7749ab4b2c81eb47')
+
+pkgver() {
+ cd "${srcdir}/SFML"
+ git describe --long --tags | sed -r 's/([^-]*-g)/r\1/;s/-/./g'
+}
+
+prepare() {
+ cd "$srcdir/SFML"
+ patch -p0 -i "$srcdir/0001-fix_cmake_module_install_path.patch"
+}
+
+build() {
+ cd "$srcdir/SFML"
+
+ cmake -DCMAKE_INSTALL_PREFIX=/usr . \
+ -DCMAKE_BUILD_TYPE=RelWithDebugInfo \
+ -DBUILD_DOC=true \
+ -DBUILD_EXAMPLES=false
+ make
+ make doc
+}
+
+package() {
+ cd "$srcdir/SFML"
+
+ make DESTDIR="$pkgdir/" install
+
+ install -Dm644 ./license.txt ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
+
+}
+
+# vim:set ts=2 sw=2 et:
diff --git a/sfml-git.install b/sfml-git.install
new file mode 100644
index 00000000000..75f760be6a5
--- /dev/null
+++ b/sfml-git.install
@@ -0,0 +1,3 @@
+post_install() {
+ echo "To view the SFML samples, go to /usr/share/SFML/examples/ and run them individually"
+}