diff options
author | Bart Ribbers <bribbers@disroot.org> | 2019-12-27 22:05:00 +0100 |
---|---|---|
committer | Leo <thinkabit.ukim@gmail.com> | 2019-12-28 04:12:44 +0100 |
commit | e32670041e6103af08f073e8adefba4b2054132a (patch) | |
tree | 6db0329bc874c413593d4b255539799de878a444 | |
parent | 22229de290565d097307ca9a6978cec74fda388b (diff) | |
download | aports-e32670041e6103af08f073e8adefba4b2054132a.zip |
testing/libgnome-games-support: new aport
-rw-r--r-- | testing/libgnome-games-support/APKBUILD | 35 | ||||
-rw-r--r-- | testing/libgnome-games-support/meson-support.patch | 170 |
2 files changed, 205 insertions, 0 deletions
diff --git a/testing/libgnome-games-support/APKBUILD b/testing/libgnome-games-support/APKBUILD new file mode 100644 index 00000000000..97624516cf4 --- /dev/null +++ b/testing/libgnome-games-support/APKBUILD @@ -0,0 +1,35 @@ +# Contributor: Bart Ribbers <bribbers@disroot.org> +# Maintainer: Rasmus Thomsen <oss@cogitri.dev> +pkgname=libgnome-games-support +pkgver=1.4.4 +pkgrel=0 +arch="all" +url="https://gitlab.gnome.org/GNOME/libgnome-games-support" +pkgdesc="Code shared between GNOME games" +license="LGPL-3.0-or-later" +makedepends="meson ninja vala libgee-dev gtk+3.0-dev" +source="https://download.gnome.org/sources/libgnome-games-support/${pkgver%.*}/libgnome-games-support-$pkgver.tar.xz + meson-support.patch" +subpackages="$pkgname-dev $pkgname-lang" + +build() { + meson \ + --prefix=/usr \ + --sysconfdir=/sys \ + --mandir=/usr/share/man \ + --localstatedir=/var \ + --buildtype=release \ + . output + ninja -C output +} + +check() { + ninja test -C output +} + +package() { + DESTDIR="$pkgdir" ninja install -C output +} + +sha512sums="2b2c77210103610cb91554f870d634bc8d06f0886eef5166bf9909c1975a87d960005640d48e3e917f74c7553e3ae07d473ba06c6c5d6582313c50a390ec6168 libgnome-games-support-1.4.4.tar.xz +3fdff90e5f4908b073234472716a2dd419d04772529c9c3cdff3a68e422e12c08578f023227607a1d4c90dac9b73f00b93c1f1cbec2623f2677c2d8d6399c89e meson-support.patch" diff --git a/testing/libgnome-games-support/meson-support.patch b/testing/libgnome-games-support/meson-support.patch new file mode 100644 index 00000000000..01ef09e60d3 --- /dev/null +++ b/testing/libgnome-games-support/meson-support.patch @@ -0,0 +1,170 @@ +From eb0f326381f1d3dca219d2140643d05db9af537e Mon Sep 17 00:00:00 2001 +From: Arnaud B <arnaud.bonatti@gmail.com> +Date: Thu, 31 Oct 2019 20:48:04 +0000 +Subject: [PATCH] Add Meson support + +https://wiki.gnome.org/Initiatives/GnomeGoals/MesonPorting + +https://gitlab.gnome.org/GNOME/libgnome-games-support/merge_requests/2 + +Co-Authored-By: Jan Tojnar <jtojnar@gmail.com> +Co-Authored-By: Michael Catanzaro <mcatanzaro@gnome.org> +--- + games/meson.build | 56 +++++++++++++++++++++++++++++++++++++++++++++++ + meson.build | 46 ++++++++++++++++++++++++++++++++++++++ + po/meson.build | 1 + + tests/meson.build | 18 +++++++++++++++ + 4 files changed, 121 insertions(+) + create mode 100644 games/meson.build + create mode 100644 meson.build + create mode 100644 po/meson.build + create mode 100644 tests/meson.build + +diff --git a/games/meson.build b/games/meson.build +new file mode 100644 +index 0000000..bb551ab +--- /dev/null ++++ b/games/meson.build +@@ -0,0 +1,56 @@ ++includesubdir = 'gnome-games-support-1' ++ ++lggs_interface_deps = [ ++ gee_dependency, ++ gio_dependency, ++ glib_dependency, ++ gtk_dependency, ++] ++ ++lggs = library('gnome-games-support-1', ++ [ ++ 'config.vapi', ++ 'gridframe.vala', ++ 'scores/category.vala', ++ 'scores/context.vala', ++ 'scores/dialog.vala', ++ 'scores/directory-importer.vala', ++ 'scores/history-file-importer.vala', ++ 'scores/importer.vala', ++ 'scores/score.vala', ++ ], ++ install: true, ++ install_dir: [ ++ true, # default libdir ++ join_paths(includedir, includesubdir), # headers ++ true, # default vapidir ++ ], ++ c_args: [ ++ # https://github.com/mesonbuild/meson/issues/4763 ++ '-include', 'config.h' ++ ], ++ vala_header: 'libgnome-games-support.h', ++ vala_vapi: 'libgnome-games-support-1.vapi', ++ vala_args: [ ++ '--abi-stability', ++ '--target-glib=2.44', ++ ], ++ soversion: soversion, ++ version: library_version, ++ dependencies: lggs_interface_deps, ++) ++ ++lggs_dependency = declare_dependency( ++ link_with: lggs, ++ include_directories: include_directories('.'), ++) ++ ++pkg = import('pkgconfig') ++pkg.generate( ++ lggs, ++ filebase: 'libgnome-games-support-1', ++ requires: lggs_interface_deps, ++ name: meson.project_name(), ++ description: 'Useful functionality shared among GNOME games', ++ subdirs: includesubdir, ++) +diff --git a/meson.build b/meson.build +new file mode 100644 +index 0000000..8aad65e +--- /dev/null ++++ b/meson.build +@@ -0,0 +1,46 @@ ++project( ++ 'libgnome-games-support', ['vala', 'c'], ++ version: '1.4.4', ++ license: 'LGPLv3+', ++ meson_version: '>= 0.50.0', ++) ++ ++# Before making a release, the library_version string should be modified. ++# ++# * Bump the first component if binary compatibility has been broken; or ++# * Bump the second component if new APIs are added; or ++# * Bump the third component otherwise. ++# ++# When bumping the first component version, set the second and third components ++# to 0. When bumping the second version, set the third one to zero. ++# ++# A lot easier than libtool, right? ++library_version = '3.0.1' ++soversion = library_version.split('.')[0] ++ ++# used to install help ++gnome = import('gnome') ++# used for internationalization ++i18n = import('i18n') ++ ++cc = meson.get_compiler('c') ++valac = meson.get_compiler('vala') # TODO 0.39.6 min ++ ++gee_dependency = dependency('gee-0.8', version: '>= 0.14.0') ++gio_dependency = dependency('gio-2.0', version: '>= 2.40.0') ++glib_dependency = dependency('glib-2.0', version: '>= 2.40.0') ++gtk_dependency = dependency('gtk+-3.0', version: '>= 3.19.2') ++ ++localedir = join_paths(get_option('prefix'), get_option('localedir')) ++includedir = join_paths(get_option('prefix'), get_option('includedir')) ++ ++conf = configuration_data() ++conf.set_quoted('VERSION', meson.project_version()) ++conf.set_quoted('GETTEXT_PACKAGE', meson.project_name()) ++conf.set_quoted('LOCALEDIR', localedir) ++ ++configure_file(output: 'config.h', configuration: conf) ++ ++subdir('po') ++subdir('games') ++subdir('tests') +diff --git a/po/meson.build b/po/meson.build +new file mode 100644 +index 0000000..e9b77d7 +--- /dev/null ++++ b/po/meson.build +@@ -0,0 +1 @@ ++i18n.gettext(meson.project_name(), preset: 'glib') +diff --git a/tests/meson.build b/tests/meson.build +new file mode 100644 +index 0000000..9f6ce1c +--- /dev/null ++++ b/tests/meson.build +@@ -0,0 +1,18 @@ ++lggs_tests = executable( ++ 'libgnome-games-support-tests', ++ [ 'test-scores.vala' ], ++ vala_args: [ ++ '--target-glib=2.44', ++ ], ++ dependencies: [ ++ gee_dependency, ++ glib_dependency, ++ gtk_dependency, ++ lggs_dependency, ++ ], ++) ++test( ++ 'libgnome-games-support-tests', ++ lggs_tests, ++ timeout: 1, ++) +-- +2.24.1 + |