diff options
author | Alyssa Ross <hi@alyssa.is> | 2020-01-11 23:37:02 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2020-01-11 23:41:30 +0000 |
commit | 6c557e3f1c28cf87e9fba232811d6875dd1399c1 (patch) | |
tree | 035a071d5d8980df6de0fa42e2ef8fc0cce7055e /nixpkgs/pkgs/development/libraries/gcab | |
parent | da7500bc026e937ac7fce7b50f67a0e1765737a7 (diff) | |
parent | e4134747f5666bcab8680aff67fa3b63384f9a0f (diff) | |
download | nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.gz nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.bz2 nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.lz nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.xz nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.zst nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.zip |
Merge commit 'e4134747f5666bcab8680aff67fa3b63384f9a0f'
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/gcab')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/gcab/default.nix | 69 | ||||
-rw-r--r-- | nixpkgs/pkgs/development/libraries/gcab/installed-tests-path.patch | 21 |
2 files changed, 78 insertions, 12 deletions
diff --git a/nixpkgs/pkgs/development/libraries/gcab/default.nix b/nixpkgs/pkgs/development/libraries/gcab/default.nix index ee5988b30f57..c05bb95913e6 100644 --- a/nixpkgs/pkgs/development/libraries/gcab/default.nix +++ b/nixpkgs/pkgs/development/libraries/gcab/default.nix @@ -1,38 +1,83 @@ -{ stdenv, fetchurl, gettext, gobject-introspection, pkgconfig -, meson, ninja, glibcLocales, git, vala, glib, zlib, gnome3 +{ stdenv +, fetchurl +, gettext +, gobject-introspection +, gtk-doc +, docbook_xsl +, docbook_xml_dtd_43 +, pkgconfig +, meson +, ninja +, git +, vala +, glib +, zlib +, gnome3 +, nixosTests }: stdenv.mkDerivation rec { pname = "gcab"; - version = "1.2"; + version = "1.3"; - LC_ALL = "en_US.UTF-8"; + outputs = [ "bin" "out" "dev" "devdoc" "installedTests" ]; src = fetchurl { url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz"; - sha256 = "038h5kk41si2hc9d9169rrlvp8xgsxq27kri7hv2vr39gvz9cbas"; + sha256 = "1rv81b37d5ya7xpfdxrfk173jjcwabxyng7vafgwyl5myv44qc0h"; }; - nativeBuildInputs = [ meson ninja glibcLocales git pkgconfig vala gettext gobject-introspection ]; + patches = [ + # allow installing installed tests to a separate output + ./installed-tests-path.patch + ]; - buildInputs = [ glib zlib ]; + nativeBuildInputs = [ + meson + ninja + git + pkgconfig + vala + gettext + gobject-introspection + gtk-doc + docbook_xsl + docbook_xml_dtd_43 + ]; + + buildInputs = [ + glib + zlib + ]; + + # required by libgcab-1.0.pc + propagatedBuildInputs = [ + glib + ]; mesonFlags = [ - "-Ddocs=false" - "-Dtests=false" + "-Dinstalled_tests=true" + "-Dinstalled_test_prefix=${placeholder ''installedTests''}" ]; + doCheck = true; + passthru = { updateScript = gnome3.updateScript { packageName = pname; versionPolicy = "none"; }; + + tests = { + installedTests = nixosTests.installed-tests.gcab; + }; }; meta = with stdenv.lib; { + description = "GObject library to create cabinet files"; + homepage = "https://gitlab.gnome.org/GNOME/gcab"; + license = licenses.lgpl21Plus; + maintainers = gnome3.maintainers; platforms = platforms.linux; - license = licenses.lgpl21; - homepage = "https://wiki.gnome.org/msitools"; - maintainers = [ maintainers.lethalman ]; }; } diff --git a/nixpkgs/pkgs/development/libraries/gcab/installed-tests-path.patch b/nixpkgs/pkgs/development/libraries/gcab/installed-tests-path.patch new file mode 100644 index 000000000000..ab3b6b3fae3f --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/gcab/installed-tests-path.patch @@ -0,0 +1,21 @@ +diff --git a/meson_options.txt b/meson_options.txt +index c1b1da1..9b76022 100644 +--- a/meson_options.txt ++++ b/meson_options.txt +@@ -4,3 +4,4 @@ + option('vapi', type : 'boolean', value : true, description: 'generate Vala bindings (requires introspection)') + option('tests', type : 'boolean', value : true, description : 'enable tests') + option('installed_tests', type : 'boolean', value : false, description : 'install tests for "as-installed" testing') ++option('installed_test_prefix', type: 'string', value: '', description: 'Prefix for installed tests') +diff --git a/tests/meson.build b/tests/meson.build +index 1e46e2a..aa780d0 100644 +--- a/tests/meson.build ++++ b/tests/meson.build +@@ -1,5 +1,5 @@ +-installed_tests_metadir = join_paths(get_option('datadir'), 'installed-tests', 'libgcab-1.0') +-installed_tests_execdir = join_paths(get_option('libexecdir'), 'installed-tests', 'libgcab-1.0') ++installed_tests_metadir = join_paths(get_option('installed_test_prefix'), 'share', 'installed-tests', 'libgcab-1.0') ++installed_tests_execdir = join_paths(get_option('installed_test_prefix'), 'libexec', 'installed-tests', 'libgcab-1.0') + installed_tests_enabled = get_option('installed_tests') + installed_tests_template_tap = files('template-tap.test.in') + abs_installed_tests_execdir = join_paths(get_option('prefix'), installed_tests_execdir) |