diff options
-rw-r--r-- | .SRCINFO | 20 | ||||
-rw-r--r-- | PKGBUILD | 48 |
2 files changed, 37 insertions, 31 deletions
@@ -1,24 +1,18 @@ pkgbase = ags pkgdesc = Engine to run adventure/quest games - pkgver = 3.5.1.9 + pkgver = 3.6.1.24 pkgrel = 1 url = https://github.com/adventuregamestudio/ags arch = x86_64 license = Artistic2.0 makedepends = cmake - makedepends = wxgtk2 - depends = dumb-a4 + depends = sdl2 + depends = sdl2_sound + depends = libogg depends = libtheora + depends = libvorbis depends = freetype2 - depends = sdl2 - depends = alsa-lib - depends = jack - depends = libx11 - depends = libxext - depends = libxcursor - depends = libxpm - depends = libxxf86vm - source = ags-3.5.1.9.tar.gz::https://github.com/adventuregamestudio/ags/archive/v.3.5.1.9.tar.gz - sha256sums = 001b6af0e454351039b5bd3d7626fcaf6d9453ac337a0e6a03cad210ea30345e + source = ags-3.6.1.24.tar.gz::https://github.com/adventuregamestudio/ags/archive/v3.6.1.24.tar.gz + sha256sums = 1dc22409d2a5501a2912b22f97feb0ba962bf4067737ce1339447ea9e467ea1c pkgname = ags @@ -5,32 +5,44 @@ # Contributor: xyproto pkgname=ags -pkgver=3.5.1.9 +pkgver=3.6.1.24 pkgrel=1 pkgdesc='Engine to run adventure/quest games' arch=('x86_64') url='https://github.com/adventuregamestudio/ags' license=('Artistic2.0') -# ags depends on Allegro 4 and do not have plans to upgrade - they intend to replace Allegro entirely with SDL. -# https://github.com/adventuregamestudio/ags/issues/403 -# https://github.com/adventuregamestudio/ags/issues/762 -# https://github.com/adventuregamestudio/ags/issues/1051#issuecomment-602217650 -depends=('dumb-a4' 'libtheora' 'freetype2' 'sdl2' 'alsa-lib' 'jack' 'libx11' 'libxext' 'libxcursor' 'libxpm' 'libxxf86vm') -makedepends=('cmake' 'wxgtk2') -source=("$pkgname-$pkgver.tar.gz::https://github.com/adventuregamestudio/ags/archive/v.$pkgver.tar.gz") -sha256sums=('001b6af0e454351039b5bd3d7626fcaf6d9453ac337a0e6a03cad210ea30345e') +depends=('sdl2' 'sdl2_sound' 'libogg' 'libtheora' 'libvorbis' 'freetype2') +makedepends=('cmake') +source=("$pkgname-$pkgver.tar.gz::https://github.com/adventuregamestudio/ags/archive/v$pkgver.tar.gz") +sha256sums=('1dc22409d2a5501a2912b22f97feb0ba962bf4067737ce1339447ea9e467ea1c') + +_srcdir="$pkgname-$pkgver" + +prepare() { + cd "$_srcdir" + + sed -i '/include_directories("${SDL_sound_INCLUDE_DIRS}")/d' 'CMakeLists.txt' + sed -i 's/find_package(SDL_sound REQUIRED)/find_package(SDL2_sound REQUIRED)/' 'CMakeLists.txt' + sed -i 's|add_subdirectory(Common/libsrc/freetype-2.1.3 EXCLUDE_FROM_ALL)|find_package(Freetype REQUIRED)|' 'CMakeLists.txt' + sed -i 's|set(FREETYPE_LIBRARIES FreeType::FreeType)|set(FREETYPE_LIBRARIES Freetype::Freetype)|' 'CMakeLists.txt' +} build() { - cmake -S "ags-v.$pkgver" -B 'build' \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DCMAKE_BUILD_TYPE='Release' \ - -DCMAKE_C_FLAGS_RELEASE='-DNDEBUG -w' \ - -DCMAKE_CXX_FLAGS_RELEASE='-DNDEBUG -w' - cmake --build 'build' + cmake -S "$_srcdir" -B 'build' \ + -DCMAKE_INSTALL_PREFIX='/usr' \ + -DCMAKE_BUILD_TYPE=None \ + -DAGS_USE_LOCAL_ALL_LIBRARIES=ON \ + -DAGS_BUILD_TOOLS=ON + cmake --build 'build' +} + +check() { + cmake -S "$_srcdir" -B 'build' -DAGS_TESTS=ON + cmake --build 'build' + cmake --build 'build' --target test } package() { - #cd "ags-v.$pkgver" - #DESTDIR="${pkgdir}" cmake --install "build" - install -Dm755 'build/ags' -t "$pkgdir/usr/bin/" + DESTDIR="${pkgdir}" cmake --install 'build' + install -Dm644 "${_srcdir}/License.txt" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" } |