diff options
Diffstat (limited to 'pkgs/development/tools/misc/unifdef/default.nix')
-rw-r--r-- | pkgs/development/tools/misc/unifdef/default.nix | 31 |
1 files changed, 12 insertions, 19 deletions
diff --git a/pkgs/development/tools/misc/unifdef/default.nix b/pkgs/development/tools/misc/unifdef/default.nix index 19dd907b73b..ebb034a92e7 100644 --- a/pkgs/development/tools/misc/unifdef/default.nix +++ b/pkgs/development/tools/misc/unifdef/default.nix @@ -1,31 +1,24 @@ -{ fetchurl, stdenv }: +{ lib, stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "unifdef-2.6"; + pname = "unifdef"; + version = "2.12"; src = fetchurl { - url = "https://github.com/fanf2/unifdef/archive/${name}.tar.gz"; - sha256 = "1p5wr5ms9w8kijy9h7qs1mz36dlavdj6ngz2bks588w7a20kcqxj"; + url = "https://dotat.at/prog/unifdef/unifdef-${version}.tar.xz"; + sha256 = "00647bp3m9n01ck6ilw6r24fk4mivmimamvm4hxp5p6wxh10zkj3"; }; - postUnpack = '' - substituteInPlace $sourceRoot/unifdef.c \ - --replace '#include "version.h"' "" + makeFlags = [ + "prefix=$(out)" + "DESTDIR=" + ]; - substituteInPlace $sourceRoot/Makefile \ - --replace "unifdef.c: version.h" "unifdef.c:" - ''; - - preBuild = '' - unset HOME - export DESTDIR=$out - ''; - - meta = with stdenv.lib; { - homepage = "http://dotat.at/prog/unifdef/"; + meta = with lib; { + homepage = "https://dotat.at/prog/unifdef/"; description = "Selectively remove C preprocessor conditionals"; license = licenses.bsd2; platforms = platforms.unix; - maintainers = [ maintainers.vrthra ]; + maintainers = with maintainers; [ orivej vrthra ]; }; } |