Skip to content

Commit

Permalink
wcslib: refactor and fix noBrokenSymlinks (#380492)
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfgangwalther authored Feb 12, 2025
2 parents 32a564c + 914f4e5 commit 3f41fb0
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions pkgs/by-name/wc/wcslib/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ stdenv.mkDerivation rec {

src = fetchurl {
url = "ftp://ftp.atnf.csiro.au/pub/software/wcslib/${pname}-${version}.tar.bz2";
sha256 = "sha256-lguERCbRSotTze7XgliqkojN7ZmncywGZ8ZPpqUBJtw=";
hash = "sha256-lguERCbRSotTze7XgliqkojN7ZmncywGZ8ZPpqUBJtw=";
};

nativeBuildInputs = [ flex ];
Expand All @@ -23,16 +23,25 @@ stdenv.mkDerivation rec {
"man"
];

meta = with lib; {
# DOCDIR is set to the path $out/share/doc/wcslib, and DOCLINK points
# to the same location.
# `$(LN_S) $(notdir $(DOCDIR)) $(DOCLINK)` effectively running:
# `ln -s wcslib $out/share/doc/wcslib`
# This produces a broken link because the target location already exists
postInstall = ''
rm $out/share/doc/wcslib/wcslib
'';

meta = {
homepage = "https://www.atnf.csiro.au/people/mcalabre/WCS/";
description = "World Coordinate System library for astronomy";
longDescription = ''
Library for world coordinate systems for spherical geometries
and their conversion to image coordinate systems. This is the
standard library for this purpose in astronomy.
'';
maintainers = with maintainers; [ hjones2199 ];
license = licenses.lgpl3Plus;
platforms = platforms.unix;
maintainers = with lib.maintainers; [ hjones2199 ];
license = lib.licenses.lgpl3Plus;
platforms = lib.platforms.unix;
};
}

0 comments on commit 3f41fb0

Please sign in to comment.