summaryrefslogtreecommitdiff
path: root/raylib-both/PKGBUILD
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2023-03-12 23:56:24 +0100
committerAki <please@ignore.pl>2023-03-13 00:07:32 +0100
commit62f4a0c38bf550af85984734283489189ea49af7 (patch)
tree860acc81e9248d690375dc2deaab43f61f51d99d /raylib-both/PKGBUILD
parentcca0405d5128360a580af531c4bcf1d6837576e0 (diff)
downloadarch-ignore-62f4a0c38bf550af85984734283489189ea49af7.zip
arch-ignore-62f4a0c38bf550af85984734283489189ea49af7.tar.gz
arch-ignore-62f4a0c38bf550af85984734283489189ea49af7.tar.bz2
Added raylib-both including static and dynamic builds
Diffstat (limited to 'raylib-both/PKGBUILD')
-rw-r--r--raylib-both/PKGBUILD53
1 files changed, 53 insertions, 0 deletions
diff --git a/raylib-both/PKGBUILD b/raylib-both/PKGBUILD
new file mode 100644
index 0000000..214995c
--- /dev/null
+++ b/raylib-both/PKGBUILD
@@ -0,0 +1,53 @@
+_pkgname=raylib
+pkgname=raylib-both
+pkgver=4.2.0
+pkgrel=1
+pkgdesc='Simple and easy-to-use game programming library'
+provides=($_pkgname)
+conflicts=($_pkgname)
+options=(staticlibs)
+arch=(x86_64)
+url='https://www.raylib.com'
+license=(ZLIB)
+makedepends=(cmake git libx11 libxcursor libxinerama libxrandr ninja vulkan-headers xorg-server-devel xorg-xinput)
+source=("git+https://github.com/raysan5/raylib#commit=bf2ad9df5fdcaa385b2a7f66fd85632eeebbadaa")
+b2sums=('SKIP')
+
+build() {
+ cmake \
+ -B shared \
+ -D BUILD_EXAMPLES=OFF \
+ -D BUILD_SHARED_LIBS=ON \
+ -D CMAKE_BUILD_TYPE=Release \
+ -D CMAKE_C_FLAGS="$CFLAGS -fPIC -w" \
+ -D CMAKE_INSTALL_LIBDIR=lib \
+ -D CMAKE_INSTALL_PREFIX=/usr \
+ -D OpenGL_GL_PREFERENCE=GLVND \
+ -D USE_EXTERNAL_GLFW=OFF \
+ -D WITH_PIC=ON \
+ -G Ninja \
+ -S $_pkgname \
+ -W no-dev
+ cmake \
+ -B static \
+ -D BUILD_EXAMPLES=OFF \
+ -D BUILD_SHARED_LIBS=OFF \
+ -D CMAKE_BUILD_TYPE=Release \
+ -D CMAKE_C_FLAGS="$CFLAGS -w" \
+ -D CMAKE_INSTALL_LIBDIR=lib \
+ -D CMAKE_INSTALL_PREFIX=/usr \
+ -D OpenGL_GL_PREFERENCE=GLVND \
+ -D USE_EXTERNAL_GLFW=OFF \
+ -G Ninja \
+ -S $_pkgname \
+ -W no-dev
+ ninja -C shared
+ ninja -C static
+}
+
+package() {
+ DESTDIR="$pkgdir" ninja -C shared install
+ DESTDIR="$pkgdir" ninja -C static install
+ install -Dm 644 "$_pkgname/LICENSE" \
+ "$pkgdir/usr/share/licenses/$_pkgname/LICENSE"
+}