treewide: NIX_*_COMPILE -> string

wip/yesman
Robin Gloster 5 years ago committed by Jan Tojnar
parent 981ae25113
commit ab0cfd9e03
No known key found for this signature in database
GPG Key ID: 7FAB2A15F7A607A4
  1. 2
      pkgs/applications/audio/audacity/default.nix
  2. 4
      pkgs/applications/graphics/ahoviewer/default.nix
  3. 4
      pkgs/applications/graphics/gimp/plugins/default.nix
  4. 4
      pkgs/applications/networking/browsers/firefox/common.nix
  5. 4
      pkgs/applications/science/logic/avy/default.nix
  6. 4
      pkgs/applications/video/aegisub/default.nix
  7. 4
      pkgs/applications/video/mplayer/default.nix
  8. 8
      pkgs/desktops/gnome-3/core/gnome-settings-daemon/default.nix
  9. 2
      pkgs/development/libraries/argp-standalone/default.nix
  10. 6
      pkgs/development/libraries/aws-c-common/default.nix
  11. 4
      pkgs/development/libraries/glm/default.nix
  12. 4
      pkgs/development/libraries/gpgme/default.nix
  13. 2
      pkgs/development/libraries/gsl/default.nix
  14. 2
      pkgs/development/libraries/gsl/gsl-1_16.nix
  15. 2
      pkgs/development/libraries/libbluray/default.nix
  16. 2
      pkgs/development/libraries/libunique/default.nix
  17. 2
      pkgs/development/libraries/opencv/3.x.nix
  18. 4
      pkgs/development/libraries/qt-4.x/4.8/default.nix
  19. 4
      pkgs/development/libraries/qt-5/mkDerivation.nix
  20. 17
      pkgs/development/libraries/qt-5/modules/qtbase.nix
  21. 2
      pkgs/development/libraries/tinyxml/2.6.2.nix
  22. 2
      pkgs/development/libraries/usbredir/default.nix
  23. 2
      pkgs/development/libraries/wxwidgets/2.8/default.nix
  24. 4
      pkgs/games/airstrike/default.nix
  25. 2
      pkgs/games/armagetronad/default.nix
  26. 2
      pkgs/servers/mail/archiveopteryx/default.nix
  27. 2
      pkgs/servers/nosql/arangodb/default.nix
  28. 2
      pkgs/servers/sql/postgresql/default.nix
  29. 2
      pkgs/tools/graphics/appleseed/default.nix
  30. 2
      pkgs/tools/graphics/asymptote/default.nix
  31. 2
      pkgs/tools/graphics/zbar/default.nix
  32. 3
      pkgs/tools/networking/altermime/default.nix
  33. 2
      pkgs/tools/networking/atinout/default.nix
  34. 2
      pkgs/tools/video/mjpegtools/default.nix

@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
];
# audacity only looks for lame and ffmpeg at runtime, so we need to link them in manually
NIX_LDFLAGS = [
NIX_LDFLAGS = toString [
# LAME
"-lmp3lame"
# ffmpeg

@ -29,9 +29,7 @@ stdenv.mkDerivation rec {
gst_all_1.gst-plugins-base
] ++ stdenv.lib.optional useUnrar unrar;
NIX_LDFLAGS = [
"-lpthread"
];
NIX_LDFLAGS = "-lpthread";
postPatch = ''patchShebangs version.sh'';

@ -48,7 +48,7 @@ stdenv.lib.makeScope pkgs.newScope (self: with self; {
url = https://ftp.gimp.org/pub/gimp/plug-ins/v2.6/gap/gimp-gap-2.6.0.tar.bz2;
sha256 = "1jic7ixcmsn4kx2cn32nc5087rk6g8xsrz022xy11yfmgvhzb0ql";
};
NIX_LDFLAGS = [ "-lm" ];
NIX_LDFLAGS = "-lm";
patchPhase = ''
sed -e 's,^\(GIMP_PLUGIN_DIR=\).*,\1'"$out/${gimp.name}-plugins", \
-e 's,^\(GIMP_DATA_DIR=\).*,\1'"$out/share/${gimp.name}", -i configure
@ -141,7 +141,7 @@ stdenv.lib.makeScope pkgs.newScope (self: with self; {
Filters/Enhance/Wavelet sharpen
*/
name = "wavelet-sharpen-0.1.2";
NIX_LDFLAGS = [ "-lm" ];
NIX_LDFLAGS = "-lm";
src = fetchurl {
url = http://registry.gimp.org/files/wavelet-sharpen-0.1.2.tar.gz;
sha256 = "0vql1k67i21g5ivaa1jh56rg427m0icrkpryrhg75nscpirfxxqw";

@ -156,7 +156,7 @@ stdenv.mkDerivation rec {
AVFoundation MediaToolbox CoreLocation
Foundation libobjc AddressBook cups ];
NIX_CFLAGS_COMPILE = [
NIX_CFLAGS_COMPILE = toString ([
"-I${glib.dev}/include/gio-unix-2.0"
]
++ lib.optionals (!isTorBrowserLike) [
@ -164,7 +164,7 @@ stdenv.mkDerivation rec {
]
++ lib.optional (pname == "firefox-esr" && lib.versionAtLeast ffversion "68"
&& lib.versionOlder ffversion "69")
"-Wno-error=format-security";
"-Wno-error=format-security");
postPatch = lib.optionalString (lib.versionAtLeast ffversion "63.0" && !isTorBrowserLike) ''
substituteInPlace third_party/prio/prio/rand.c --replace 'nspr/prinit.h' 'prinit.h'

@ -12,14 +12,14 @@ stdenv.mkDerivation {
};
buildInputs = [ cmake zlib boost.out boost.dev ];
NIX_CFLAGS_COMPILE = [ "-Wno-narrowing" ]
NIX_CFLAGS_COMPILE = toString ([ "-Wno-narrowing" ]
# Squelch endless stream of warnings on same few things
++ stdenv.lib.optionals stdenv.cc.isClang [
"-Wno-empty-body"
"-Wno-tautological-compare"
"-Wc++11-compat-deprecated-writable-strings"
"-Wno-deprecated"
];
]);
prePatch = ''
sed -i -e '1i#include <stdint.h>' abc/src/bdd/dsd/dsd.h

@ -108,9 +108,7 @@ stdenv.mkDerivation
# this is fixed upstream though not yet in an officially released version,
# should be fine remove on next release (if one ever happens)
NIX_LDFLAGS = [
"-lpthread"
];
NIX_LDFLAGS = "-lpthread";
postInstall = "ln -s $out/bin/aegisub-* $out/bin/aegisub";

@ -195,11 +195,11 @@ stdenv.mkDerivation rec {
echo CONFIG_MPEGAUDIODSP=yes >> config.mak
'';
NIX_LDFLAGS = with stdenv.lib;
NIX_LDFLAGS = with stdenv.lib; toString (
optional fontconfigSupport "-lfontconfig"
++ optional fribidiSupport "-lfribidi"
++ optionals x11Support [ "-lX11" "-lXext" ]
;
);
installTargets = [ "install" ] ++ stdenv.lib.optional x11Support "install-gui";

@ -99,11 +99,9 @@ stdenv.mkDerivation rec {
"-Dudev_dir=${placeholder "out"}/lib/udev"
];
NIX_CFLAGS_COMPILE = [
# Default for release buildtype but passed manually because
# we're using plain
"-DG_DISABLE_CAST_CHECKS"
];
# Default for release buildtype but passed manually because
# we're using plain
NIX_CFLAGS_COMPILE = "-DG_DISABLE_CAST_CHECKS";
# So the polkit policy can reference /run/current-system/sw/bin/gnome-settings-daemon/gsd-backlight-helper
postFixup = ''

@ -31,7 +31,7 @@ stdenv.mkDerivation {
stdenv.lib.optionals stdenv.hostPlatform.isDarwin [ patch-argp-fmtstream ]
++ stdenv.lib.optionals stdenv.hostPlatform.isLinux [ patch-throw-in-funcdef patch-shared ];
patchFlags = stdenv.lib.optionalString stdenv.hostPlatform.isDarwin "-p0";
patchFlags = stdenv.lib.optional stdenv.hostPlatform.isDarwin "-p0";
preConfigure = stdenv.lib.optionalString stdenv.hostPlatform.isLinux "export CFLAGS='-fgnu89-inline'";

@ -13,10 +13,8 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake ];
NIX_CFLAGS_COMPILE = lib.optionals stdenv.isDarwin [
"-Wno-nullability-extension"
"-Wno-typedef-redefinition"
];
NIX_CFLAGS_COMPILE = lib.optionalString stdenv.isDarwin
"-Wno-nullability-extension -Wno-typedef-redefinition";
meta = with lib; {
description = "AWS SDK for C common core";

@ -27,9 +27,7 @@ stdenv.mkDerivation rec {
cp ${gcc7PlatformPatch} glm/simd/platform.h
'';
NIX_CFLAGS_COMPILE = stdenv.lib.optionals stdenv.isDarwin [
"-DGLM_COMPILER=0"
];
NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.isDarwin "-DGLM_COMPILER=0";
postInstall = ''
mkdir -p $doc/share/doc/glm

@ -47,12 +47,12 @@ stdenv.mkDerivation rec {
# fit in the limit. https://github.com/NixOS/nix/pull/1085
++ lib.optionals stdenv.isDarwin [ "--disable-gpg-test" ];
NIX_CFLAGS_COMPILE =
NIX_CFLAGS_COMPILE = toString (
# qgpgme uses Q_ASSERT which retains build inputs at runtime unless
# debugging is disabled
lib.optional (qtbase != null) "-DQT_NO_DEBUG"
# https://www.gnupg.org/documentation/manuals/gpgme/Largefile-Support-_0028LFS_0029.html
++ lib.optional (system == "i686-linux") "-D_FILE_OFFSET_BITS=64";
++ lib.optional (system == "i686-linux") "-D_FILE_OFFSET_BITS=64");
checkInputs = [ which ];

@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
};
# do not let -march=skylake to enable FMA (https://lists.gnu.org/archive/html/bug-gsl/2011-11/msg00019.html)
NIX_CFLAGS_COMPILE = stdenv.lib.optional stdenv.isx86_64 "-mno-fma";
NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.isx86_64 "-mno-fma";
# https://lists.gnu.org/archive/html/bug-gsl/2015-11/msg00012.html
doCheck = stdenv.hostPlatform.system != "i686-linux" && stdenv.hostPlatform.system != "aarch64-linux";

@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
};
# do not let -march=skylake to enable FMA (https://lists.gnu.org/archive/html/bug-gsl/2011-11/msg00019.html)
NIX_CFLAGS_COMPILE = stdenv.lib.optional stdenv.isx86_64 "-mno-fma";
NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.isx86_64 "-mno-fma";
patches = [
(fetchpatch {

@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
propagatedBuildInputs = optional withAACS libaacs;
NIX_LDFLAGS = [
NIX_LDFLAGS = toString [
(optionalString withAACS "-L${libaacs}/lib -laacs")
(optionalString withBDplus "-L${libbdplus}/lib -lbdplus")
];

@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
};
# glib-2.62 deprecations
NIX_CFLAGS_COMPILE = [ "-DGLIB_DISABLE_DEPRECATION_WARNINGS" ];
NIX_CFLAGS_COMPILE = "-DGLIB_DISABLE_DEPRECATION_WARNINGS";
# Patches from Gentoo portage
patches = [

@ -208,7 +208,7 @@ stdenv.mkDerivation {
nativeBuildInputs = [ cmake pkgconfig unzip ];
NIX_CFLAGS_COMPILE = lib.optional enableEXR "-I${ilmbase.dev}/include/OpenEXR";
NIX_CFLAGS_COMPILE = lib.optionalString enableEXR "-I${ilmbase.dev}/include/OpenEXR";
# Configure can't find the library without this.
OpenBLAS_HOME = lib.optionalString enableOpenblas openblas;

@ -206,13 +206,13 @@ stdenv.mkDerivation rec {
enableParallelBuilding = true;
NIX_CFLAGS_COMPILE =
NIX_CFLAGS_COMPILE = toString (
# with gcc7 the warnings blow the log over Hydra's limit
[ "-Wno-expansion-to-defined" "-Wno-unused-local-typedefs" ]
++ lib.optional stdenv.isLinux "-std=gnu++98" # gnu++ in (Obj)C flags is no good on Darwin
++ lib.optionals (stdenv.isFreeBSD || stdenv.isDarwin)
[ "-I${glib.dev}/include/glib-2.0" "-I${glib.out}/lib/glib-2.0/include" ]
++ lib.optional stdenv.isDarwin "-I${libcxx}/include/c++/v1";
++ lib.optional stdenv.isDarwin "-I${libcxx}/include/c++/v1");
NIX_LDFLAGS = lib.optionalString (stdenv.isFreeBSD || stdenv.isDarwin) "-lglib-2.0";

@ -12,9 +12,9 @@ let
qmakeFlags = [ ("CONFIG+=" + (if debug then "debug" else "release")) ]
++ (args.qmakeFlags or []);
NIX_CFLAGS_COMPILE =
NIX_CFLAGS_COMPILE = toString (
optional (!debug) "-DQT_NO_DEBUG"
++ lib.toList (args.NIX_CFLAGS_COMPILE or []);
++ lib.toList (args.NIX_CFLAGS_COMPILE or []));
cmakeFlags =
(args.cmakeFlags or [])

@ -200,20 +200,17 @@ stdenv.mkDerivation {
done
'';
NIX_CFLAGS_COMPILE =
[
"-Wno-error=sign-compare" # freetype-2.5.4 changed signedness of some struct fields
''-DNIXPKGS_QTCOMPOSE="${libX11.out}/share/X11/locale"''
''-D${if compareVersion "5.11.0" >= 0 then "LIBRESOLV_SO" else "NIXPKGS_LIBRESOLV"}="${stdenv.cc.libc.out}/lib/libresolv"''
''-DNIXPKGS_LIBXCURSOR="${libXcursor.out}/lib/libXcursor"''
]
++ lib.optional libGLSupported ''-DNIXPKGS_MESA_GL="${libGL.out}/lib/libGL"''
NIX_CFLAGS_COMPILE = toString ([
"-Wno-error=sign-compare" # freetype-2.5.4 changed signedness of some struct fields
''-DNIXPKGS_QTCOMPOSE="${libX11.out}/share/X11/locale"''
''-D${if compareVersion "5.11.0" >= 0 then "LIBRESOLV_SO" else "NIXPKGS_LIBRESOLV"}="${stdenv.cc.libc.out}/lib/libresolv"''
''-DNIXPKGS_LIBXCURSOR="${libXcursor.out}/lib/libXcursor"''
] ++ lib.optional libGLSupported ''-DNIXPKGS_MESA_GL="${libGL.out}/lib/libGL"''
++ lib.optionals withGtk3 [
''-DNIXPKGS_QGTK3_XDG_DATA_DIRS="${gtk3}/share/gsettings-schemas/${gtk3.name}"''
''-DNIXPKGS_QGTK3_GIO_EXTRA_MODULES="${dconf.lib}/lib/gio/modules"''
]
++ lib.optional decryptSslTraffic "-DQT_DECRYPT_SSL_TRAFFIC";
++ lib.optional decryptSslTraffic "-DQT_DECRYPT_SSL_TRAFFIC");
prefixKey = "-prefix ";

@ -28,7 +28,7 @@ in stdenv.mkDerivation {
hardeningDisable = [ "format" ];
NIX_CFLAGS_COMPILE =
stdenv.lib.optional stdenv.isDarwin "-mmacosx-version-min=10.9";
stdenv.lib.optionalString stdenv.isDarwin "-mmacosx-version-min=10.9";
buildInputs = [ unzip ];
buildPhase = ''

@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
sha256 = "002yik1x7kn0427xahvnhjby2np14a6xqw7c3dx530n9h5d9rg47";
};
NIX_CFLAGS_COMPILE = [ "-Wno-error" ];
NIX_CFLAGS_COMPILE = "-Wno-error";
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ libusb ];

@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
+ optionalString withMesa "${libGLU.out}/lib ${libGL.out}/lib ";
# Work around a bug in configure.
NIX_CFLAGS_COMPILE = [ "-DHAVE_X11_XLIB_H=1" "-lX11" "-lcairo" "-Wno-narrowing" ];
NIX_CFLAGS_COMPILE = "-DHAVE_X11_XLIB_H=1 -lX11 -lcairo -Wno-narrowing";
preConfigure = "
substituteInPlace configure --replace 'SEARCH_INCLUDE=' 'DUMMY_SEARCH_INCLUDE='

@ -11,9 +11,7 @@ stdenv.mkDerivation rec {
buildInputs = [ makeWrapper SDL SDL_image ];
NIX_LDFLAGS = [
"-lm"
];
NIX_LDFLAGS = "-lm";
installPhase = ''
ls -l

@ -14,7 +14,7 @@ stdenv.mkDerivation {
sha256 = "157pp84wf0q3bdb72rnbm3ck0czwx2ply6lyhj8z7kfdc7csdbr3";
};
NIX_LDFLAGS = [ "-lSDL_image" ];
NIX_LDFLAGS = "-lSDL_image";
enableParallelBuilding = true;

@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
'';
# fix build on gcc7+
NIX_CFLAGS_COMPILE = [
NIX_CFLAGS_COMPILE = builtins.toString [
"-Wno-error=builtin-declaration-mismatch"
"-Wno-error=implicit-fallthrough"
"-Wno-error=deprecated-copy"

@ -17,7 +17,7 @@ let
# prevent failing with "cmake-3.13.4/nix-support/setup-hook: line 10: ./3rdParty/rocksdb/RocksDBConfig.cmake.in: No such file or directory"
dontFixCmake = lib.versionAtLeast version "3.5";
NIX_CFLAGS_COMPILE = lib.optionals (lib.versionAtLeast version "3.5") [ "-Wno-error" ];
NIX_CFLAGS_COMPILE = lib.optionalString (lib.versionAtLeast version "3.5") "-Wno-error";
preConfigure = lib.optionalString (lib.versionAtLeast version "3.5") "patchShebangs utils";
postPatch = ''

@ -44,7 +44,7 @@ let
buildFlags = [ "world" ];
NIX_CFLAGS_COMPILE = [ "-I${libxml2.dev}/include/libxml2" ];
NIX_CFLAGS_COMPILE = "-I${libxml2.dev}/include/libxml2";
# Otherwise it retains a reference to compiler and fails; see #44767. TODO: better.
preConfigure = "CC=${stdenv.cc.targetPrefix}cc";

@ -24,7 +24,7 @@ in stdenv.mkDerivation rec {
osl seexpr makeWrapper
];
NIX_CFLAGS_COMPILE = [
NIX_CFLAGS_COMPILE = toString [
"-I${openexr.dev}/include/OpenEXR"
"-I${ilmbase.dev}/include/OpenEXR"
"-I${openimageio.dev}/include/OpenImageIO"

@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
"--with-context=$out/share/texmf/tex/context/third"
];
NIX_CFLAGS_COMPILE = [ "-I${boehmgc.dev}/include/gc" ];
NIX_CFLAGS_COMPILE = "-I${boehmgc.dev}/include/gc";
postInstall = ''
mv $out/share/info/asymptote/*.info $out/share/info/

@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
];
# Disable assertions which include -dev QtBase file paths.
NIX_CFLAGS_COMPILE = [ "-DQT_NO_DEBUG" ];
NIX_CFLAGS_COMPILE = "-DQT_NO_DEBUG";
configureFlags = [
"--without-python"

@ -10,7 +10,8 @@ stdenv.mkDerivation rec {
sha256 = "15zxg6spcmd35r6xbidq2fgcg2nzyv1sbbqds08lzll70mqx4pj7";
};
NIX_CFLAGS_COMPILE = [ "-Wno-error=format"
NIX_CFLAGS_COMPILE = toString [
"-Wno-error=format"
"-Wno-error=format-truncation"
"-Wno-error=pointer-compare"
"-Wno-error=memset-elt-size"

@ -4,7 +4,7 @@ stdenv.mkDerivation rec {
name = "atinout-${version}";
version = "0.9.2-alpha";
NIX_CFLAGS_COMPILE = [ "-Werror=implicit-fallthrough=0" ];
NIX_CFLAGS_COMPILE = "-Werror=implicit-fallthrough=0";
LANG = "C.UTF-8";
nativeBuildInputs = [ ronn mount ];

@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
buildInputs = [ libdv libjpeg libpng ]
++ lib.optionals (!withMinimal) [ gtk2 libX11 SDL SDL_gfx ];
NIX_CFLAGS_COMPILE = lib.optional (!withMinimal) "-I${SDL.dev}/include/SDL";
NIX_CFLAGS_COMPILE = lib.optionalString (!withMinimal) "-I${SDL.dev}/include/SDL";
postPatch = ''
sed -i -e '/ARCHFLAGS=/s:=.*:=:' configure

Loading…
Cancel
Save