about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/gom
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2019-04-27 17:06:57 +0000
committerAlyssa Ross <hi@alyssa.is>2019-04-27 17:06:57 +0000
commit373507e28edeacd168b5c240840db2dac854882a (patch)
treec73c8912afbd1a533dbc0d27da25dcd7f0d13d58 /nixpkgs/pkgs/development/libraries/gom
parentb2ac96a35da6f6b95c7197811e421270319e8d50 (diff)
parentdfd8f84aef129f1978e446b5d45ef05cd4421821 (diff)
downloadnixlib-373507e28edeacd168b5c240840db2dac854882a.tar
nixlib-373507e28edeacd168b5c240840db2dac854882a.tar.gz
nixlib-373507e28edeacd168b5c240840db2dac854882a.tar.bz2
nixlib-373507e28edeacd168b5c240840db2dac854882a.tar.lz
nixlib-373507e28edeacd168b5c240840db2dac854882a.tar.xz
nixlib-373507e28edeacd168b5c240840db2dac854882a.tar.zst
nixlib-373507e28edeacd168b5c240840db2dac854882a.zip
Merge commit 'dfd8f84aef129f1978e446b5d45ef05cd4421821'
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/gom')
-rw-r--r--nixpkgs/pkgs/development/libraries/gom/default.nix73
-rw-r--r--nixpkgs/pkgs/development/libraries/gom/longer-stress-timeout.patch13
2 files changed, 86 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/gom/default.nix b/nixpkgs/pkgs/development/libraries/gom/default.nix
new file mode 100644
index 000000000000..5694c50e90a3
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/gom/default.nix
@@ -0,0 +1,73 @@
+{ stdenv
+, fetchurl
+, fetchpatch
+, meson
+, ninja
+, pkgconfig
+, glib
+, python3
+, sqlite
+, gdk_pixbuf
+, gnome3
+, gobject-introspection
+}:
+
+stdenv.mkDerivation rec {
+  pname = "gom";
+  version = "0.3.3";
+
+  outputs = [ "out" "py" ];
+
+  src = fetchurl {
+    url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
+    sha256 = "1n1n226dyb3q98216aah87in9hhjcwsbpspsdqqfswz2bx5y6mxc";
+  };
+
+  patches = [
+    # Needed to apply the next patch
+    (fetchpatch {
+      url = "https://gitlab.gnome.org/GNOME/gom/commit/e8b7c314ce61d459132cf03c9e455d2a01fdc6ea.patch";
+      sha256 = "0d7g3nm5lrfhfx9ly8qgf5bfp12kvr7m1xmlgin2q8vqpn0r2ggp";
+    })
+    # https://gitlab.gnome.org/GNOME/gom/merge_requests/3
+    (fetchpatch {
+      url = "https://gitlab.gnome.org/worldofpeace/gom/commit/b621c15600b1c32826c9878565eb2398a50907f2.patch";
+      sha256 = "1hqck9bb7sxn4akisnn26sbddlphjsavgksick5k4h3rsc0xwx1v";
+    })
+    ./longer-stress-timeout.patch
+  ];
+
+  nativeBuildInputs = [
+    gobject-introspection
+    meson
+    ninja
+    pkgconfig
+  ];
+
+  buildInputs = [
+    gdk_pixbuf
+    glib
+    sqlite
+    python3.pkgs.pygobject3
+  ];
+
+  mesonFlags = [
+    "-Dpygobject-override-dir=${placeholder "py"}/${python3.sitePackages}/gi/overrides"
+  ];
+
+  doCheck = true;
+
+  passthru = {
+    updateScript = gnome3.updateScript {
+      packageName = pname;
+    };
+  };
+
+  meta = with stdenv.lib; {
+    description = "A GObject to SQLite object mapper";
+    homepage = https://wiki.gnome.org/Projects/Gom;
+    license = licenses.lgpl21Plus;
+    platforms = platforms.linux;
+    maintainers = gnome3.maintainers;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/gom/longer-stress-timeout.patch b/nixpkgs/pkgs/development/libraries/gom/longer-stress-timeout.patch
new file mode 100644
index 000000000000..3dcd1d0a107f
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/gom/longer-stress-timeout.patch
@@ -0,0 +1,13 @@
+diff --git a/tests/meson.build b/tests/meson.build
+index 1df4884..d7a6f5d 100644
+--- a/tests/meson.build
++++ b/tests/meson.build
+@@ -25,7 +25,7 @@ test('test-gom-find', test_find)
+ 
+ test_stress = executable('test-gom-stress', 'test-gom-stress.c',
+   dependencies: [libgom_dep])
+-test('test-gom-stress', test_stress, timeout: 300)
++test('test-gom-stress', test_stress, timeout: 500)
+ 
+ test_transform = executable('test-gom-transform', 'test-gom-transform.c',
+   c_args: '-DIMAGE="@0@/gnome.png"'.format(meson.current_source_dir()),