16 stdenv.mkDerivation rec {
17 version = "unstable-2022-05-16";
20 src = fetchFromGitHub {
23 rev = "88c425ca2d7f4ba5d7ab75bfa25e177bee02d310";
24 sha256 = "sha256-qMMeRYIQqJpVRE3YjbXIiXHwS/CHs9l2QihszwQIr/A=";
42 "-DOPENJPEG_INCLUDE_DIR=${openjpeg.dev}/include/openjpeg-${lib.versions.majorMinor openjpeg.version}"
44 ++ lib.optionals stdenv.hostPlatform.isDarwin [ "-DLIBNOVA_LIBRARY=${libnova}/lib/libnova.dylib" ];
47 if stdenv.hostPlatform.isDarwin then
49 mkdir -p "$out/Applications" "$out/XyGrib/XyGrib.app/Contents/Resources"
50 cp "../data/img/xyGrib.icns" "$out/XyGrib/XyGrib.app/Contents/Resources/xyGrib.icns"
51 mv $out/XyGrib/XyGrib.app $out/Applications
52 wrapQtApp "$out/Applications/XyGrib.app/Contents/MacOS/XyGrib"
56 wrapQtApp $out/XyGrib/XyGrib
58 ln -s $out/XyGrib/XyGrib $out/bin/xygrib
59 install -Dm444 $src/debian/xygrib.png -t $out/share/icons/hicolor/32x32/apps
60 install -Dm444 $src/debian/xygrib.desktop -t $out/share/applications
61 substituteInPlace $out/share/applications/xygrib.desktop \
62 --replace 'Exec=XyGrib' 'Exec=xygrib'
66 homepage = "https://opengribs.org";
67 description = "Weather Forecast Visualization";
68 mainProgram = "xygrib";
70 XyGrib is a leading opensource weather visualization package.
71 It interacts with OpenGribs's Grib server providing a choice
72 of global and large area atmospheric and wave models.
74 license = licenses.gpl3;
75 platforms = platforms.all;
76 maintainers = with maintainers; [ j03 ];