geany: 1.38 -> 2.0

https://www.geany.org/documentation/releasenotes/2.0/

Upstream now supports building via Meson, which is declared experimental
at the time of writing; Autotools is still the default. [1]

The correct license for Geany is GPL-2.0-or-later, as indicated by [2].

Add a patch that disables `test_sidebar` because it runs into undefined
behavior in headless environments, and crashes at least on headless
Darwin. The patch can be removed if [3] is merged (or the issue fixed
otherwise).

[1] https://github.com/geany/geany/pull/2761/commits
[2] https://github.com/geany/geany/tree/2.0.0#license
[3] https://github.com/geany/geany/pull/3676
This commit is contained in:
6t8k 2023-11-02 21:55:46 +01:00 committed by Bjørn Forsman
parent 5c43dee215
commit cf7ed5d3df
2 changed files with 30 additions and 6 deletions

View File

@ -7,20 +7,27 @@
, file
, libintl
, hicolor-icon-theme
, python3
, wrapGAppsHook
}:
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "geany";
version = "1.38";
version = "2.0";
outputs = [ "out" "dev" "doc" "man" ];
src = fetchurl {
url = "https://download.geany.org/${pname}-${version}.tar.bz2";
sha256 = "abff176e4d48bea35ee53037c49c82f90b6d4c23e69aed6e4a5ca8ccd3aad546";
url = "https://download.geany.org/${finalAttrs.pname}-${finalAttrs.version}.tar.bz2";
hash = "sha256-VltM0vAxHB46Fn7HHEoy26ZC4P5VSuW7a4F3t6dMzJI=";
};
patches = [
# The test runs into UB in headless environments and crashes at least on headless Darwin.
# Remove if https://github.com/geany/geany/pull/3676 is merged (or the issue fixed otherwise).
./disable-test-sidebar.patch
];
nativeBuildInputs = [
pkg-config
intltool
@ -28,6 +35,7 @@ stdenv.mkDerivation rec {
which
file
hicolor-icon-theme
python3
wrapGAppsHook
];
@ -35,6 +43,11 @@ stdenv.mkDerivation rec {
gtk3
];
preCheck = ''
patchShebangs --build tests/ctags/runner.sh
patchShebangs --build scripts
'';
doCheck = true;
enableParallelBuilding = true;
@ -61,9 +74,9 @@ stdenv.mkDerivation rec {
- Plugin interface
'';
homepage = "https://www.geany.org/";
license = licenses.gpl2;
license = licenses.gpl2Plus;
maintainers = with maintainers; [ frlan ];
platforms = platforms.all;
mainProgram = "geany";
};
}
})

View File

@ -0,0 +1,11 @@
--- a/tests/Makefile.in 2023-10-19 18:10:06.000000000 +0200
+++ b/tests/Makefile.in 2023-11-10 00:13:09.816498568 +0100
@@ -86,7 +86,7 @@
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
-check_PROGRAMS = test_utils$(EXEEXT) test_sidebar$(EXEEXT)
+check_PROGRAMS = test_utils$(EXEEXT)
subdir = tests
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \