groff: remove ? null from inputs

This commit is contained in:
Sandro Jäckel 2022-07-29 23:05:11 +02:00
parent f0df0acc16
commit d11d06ba01
No known key found for this signature in database
GPG Key ID: 3AF5A43A3EECC2E5
2 changed files with 9 additions and 13 deletions

View File

@ -1,6 +1,6 @@
{ lib, stdenv, fetchurl, fetchpatch, perl { lib, stdenv, fetchurl, fetchpatch, perl
, ghostscript #for postscript and html output , enableGhostscript ? false, ghostscript # for postscript and html output
, psutils, netpbm #for html output , enableHtml ? false, psutils, netpbm # for html output
, buildPackages , buildPackages
, autoreconfHook , autoreconfHook
, pkg-config , pkg-config
@ -38,11 +38,9 @@ stdenv.mkDerivation rec {
# BASH_PROG gets replaced with a path to the build bash which doesn't get automatically patched by patchShebangs # BASH_PROG gets replaced with a path to the build bash which doesn't get automatically patched by patchShebangs
substituteInPlace contrib/gdiffmk/gdiffmk.sh \ substituteInPlace contrib/gdiffmk/gdiffmk.sh \
--replace "@BASH_PROG@" "/bin/sh" --replace "@BASH_PROG@" "/bin/sh"
'' + lib.optionalString (psutils != null) '' '' + lib.optionalString enableHtml ''
substituteInPlace src/preproc/html/pre-html.cpp \
--replace "psselect" "${psutils}/bin/psselect"
'' + lib.optionalString (netpbm != null) ''
substituteInPlace src/preproc/html/pre-html.cpp \ substituteInPlace src/preproc/html/pre-html.cpp \
--replace "psselect" "${psutils}/bin/psselect" \
--replace "pnmcut" "${lib.getBin netpbm}/bin/pnmcut" \ --replace "pnmcut" "${lib.getBin netpbm}/bin/pnmcut" \
--replace "pnmcrop" "${lib.getBin netpbm}/bin/pnmcrop" \ --replace "pnmcrop" "${lib.getBin netpbm}/bin/pnmcrop" \
--replace "pnmtopng" "${lib.getBin netpbm}/bin/pnmtopng" --replace "pnmtopng" "${lib.getBin netpbm}/bin/pnmtopng"
@ -53,8 +51,10 @@ stdenv.mkDerivation rec {
''; '';
strictDeps = true; strictDeps = true;
buildInputs = [ ghostscript psutils netpbm perl bash ];
nativeBuildInputs = [ autoreconfHook pkg-config texinfo ]; nativeBuildInputs = [ autoreconfHook pkg-config texinfo ];
buildInputs = [ perl bash ]
++ lib.optionals enableGhostscript [ ghostscript ]
++ lib.optionals enableHtml [ psutils netpbm ];
# Builds running without a chroot environment may detect the presence # Builds running without a chroot environment may detect the presence
# of /usr/X11 in the host system, leading to an impure build of the # of /usr/X11 in the host system, leading to an impure build of the
@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
configureFlags = [ configureFlags = [
"--without-x" "--without-x"
"ac_cv_path_PERL=${buildPackages.perl}/bin/perl" "ac_cv_path_PERL=${buildPackages.perl}/bin/perl"
] ++ lib.optionals (ghostscript != null) [ ] ++ lib.optionals enableGhostscript [
"--with-gs=${ghostscript}/bin/gs" "--with-gs=${ghostscript}/bin/gs"
] ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [ ] ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [
"gl_cv_func_signbit=yes" "gl_cv_func_signbit=yes"

View File

@ -6979,11 +6979,7 @@ with pkgs;
grive2 = callPackage ../tools/filesystems/grive2 { }; grive2 = callPackage ../tools/filesystems/grive2 { };
groff = callPackage ../tools/text/groff { groff = callPackage ../tools/text/groff { };
ghostscript = null;
psutils = null;
netpbm = null;
};
gromit-mpx = callPackage ../tools/graphics/gromit-mpx { gromit-mpx = callPackage ../tools/graphics/gromit-mpx {
gtk = gtk3; gtk = gtk3;