···11-{ lib, mkDerivation, fetchurl, pkg-config, qmake, qtscript, qtsvg }:
11+{ lib
22+, stdenv
33+, fetchFromGitHub
44+, cmake
55+, pkg-config
66+, qmake
77+, qtbase
88+, qtscript
99+, qtsvg
1010+, substituteAll
1111+, unzip
1212+, wrapQtAppsHook
1313+, zip
1414+}:
21533-mkDerivation rec {
1616+stdenv.mkDerivation (finalAttrs: {
417 pname = "vym";
55- version = "2.7.1";
1818+ version = "2.8.42";
61977- src = fetchurl {
88- url = "mirror://sourceforge/project/vym/${version}/${pname}-${version}.tar.bz2";
99- sha256 = "0lyf0m4y5kn5s47z4sg10215f3jsn3k1bl389jfbh2f5v4srav4g";
2020+ src = fetchFromGitHub {
2121+ owner = "insilmaril";
2222+ repo = "vym";
2323+ rev = "89f50bcba953c410caf459b0a4bfbd09018010b7"; # not tagged yet (why??)
2424+ hash = "sha256-xMXvc8gt3nfKWbU+WoS24wCUTGDQRhG0Q9m7yDhY5/w=";
1025 };
11261212- # Hardcoded paths scattered about all have form share/vym
1313- # which is encouraging, although we'll need to patch them (below).
1414- qmakeFlags = [
1515- "DATADIR=${placeholder "out"}/share"
1616- "DOCDIR=${placeholder "out"}/share/doc/vym"
2727+ patches = [
2828+ (substituteAll {
2929+ src = ./000-fix-zip-paths.diff;
3030+ zipPath = "${zip}/bin/zip";
3131+ unzipPath = "${unzip}/bin/unzip";
3232+ })
1733 ];
18341919- postPatch = ''
2020- for x in \
2121- exportoofiledialog.cpp \
2222- main.cpp \
2323- mainwindow.cpp \
2424- tex/*.{tex,lyx}; \
2525- do
2626- substituteInPlace $x \
2727- --replace /usr/share/vym $out/share/vym \
2828- --replace /usr/local/share/vym $out/share/vym \
2929- --replace /usr/share/doc $out/share/doc/vym
3030- done
3131- '';
3535+ nativeBuildInputs = [
3636+ cmake
3737+ pkg-config
3838+ wrapQtAppsHook
3939+ ];
32403333- hardeningDisable = [ "format" ];
4141+ buildInputs = [
4242+ qtbase
4343+ qtscript
4444+ qtsvg
4545+ ];
34463535- nativeBuildInputs = [ pkg-config qmake ];
3636- buildInputs = [ qtscript qtsvg ];
3737-3838- postInstall = ''
3939- install -Dm755 -t $out/share/man/man1 doc/*.1.gz
4040- '';
4747+ qtWrapperArgs = [
4848+ "--prefix PATH : ${lib.makeBinPath [ unzip zip ]}"
4949+ ];
41504251 meta = with lib; {
5252+ homepage = "http://www.insilmaril.de/vym/";
4353 description = "A mind-mapping software";
4454 longDescription = ''
4545- VYM (View Your Mind) is a tool to generate and manipulate maps which show your thoughts.
4646- Such maps can help you to improve your creativity and effectivity. You can use them
4747- for time management, to organize tasks, to get an overview over complex contexts,
4848- to sort your ideas etc.
5555+ VYM (View Your Mind) is a tool to generate and manipulate maps which show
5656+ your thoughts. Such maps can help you to improve your creativity and
5757+ effectivity. You can use them for time management, to organize tasks, to
5858+ get an overview over complex contexts, to sort your ideas etc.
49595050- Maps can be drawn by hand on paper or a flip chart and help to structure your thoughs.
5151- While a tree like structure like shown on this page can be drawn by hand or any drawing software
5252- vym offers much more features to work with such maps.
6060+ Maps can be drawn by hand on paper or a flip chart and help to structure
6161+ your thoughs. While a tree like structure like shown on this page can be
6262+ drawn by hand or any drawing software vym offers much more features to
6363+ work with such maps.
5364 '';
5454- homepage = "http://www.insilmaril.de/vym/";
5555- license = licenses.gpl2;
6565+ license = licenses.gpl2Plus;
5666 maintainers = [ maintainers.AndersonTorres ];
5767 platforms = platforms.linux;
5868 };
5959-}
6969+})