about summary refs log tree commit diff
path: root/pkgs/tools/text
diff options
context:
space:
mode:
authorArtturin <Artturin@artturin.com>2023-02-19 21:23:32 +0200
committerArtturin <Artturin@artturin.com>2023-02-22 21:23:04 +0200
commitf9fdf2d4028eac28a074c9ad75d309b3dcbf8e7a (patch)
tree01a46081dd6fc9d0a4c68be1c1844a8764bd8461 /pkgs/tools/text
parent6f6cc4a22db345c66bcb69c26469b0140ca3be44 (diff)
treewide: move NIX_CFLAGS_COMPILE to the env attrset
with structuredAttrs lists will be bash arrays which cannot be exported
which will be a issue with some patches and some wrappers like cc-wrapper

this makes it clearer that NIX_CFLAGS_COMPILE must be a string as lists
in env cause a eval failure
Diffstat (limited to 'pkgs/tools/text')
-rw-r--r--pkgs/tools/text/kytea/default.nix2
-rw-r--r--pkgs/tools/text/qgrep/default.nix2
-rw-r--r--pkgs/tools/text/sgml/jade/default.nix2
-rw-r--r--pkgs/tools/text/silver-searcher/default.nix2
-rw-r--r--pkgs/tools/text/smu/default.nix2
5 files changed, 5 insertions, 5 deletions
diff --git a/pkgs/tools/text/kytea/default.nix b/pkgs/tools/text/kytea/default.nix
index 9cbc2c030a455..322fa77ebad67 100644
--- a/pkgs/tools/text/kytea/default.nix
+++ b/pkgs/tools/text/kytea/default.nix
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   patches = [ ./gcc-O3.patch ];
 
-  NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=c++11-narrowing";
+  env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=c++11-narrowing";
 
   meta = with lib; {
     homepage = "http://www.phontron.com/kytea/";
diff --git a/pkgs/tools/text/qgrep/default.nix b/pkgs/tools/text/qgrep/default.nix
index 4145ec656d20b..ed6a409b2696c 100644
--- a/pkgs/tools/text/qgrep/default.nix
+++ b/pkgs/tools/text/qgrep/default.nix
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = lib.optionals stdenv.isDarwin [ CoreServices CoreFoundation ];
 
-  NIX_CFLAGS_COMPILE = lib.optionals (stdenv.cc.isGNU && lib.versionAtLeast stdenv.cc.version "12") [
+  env.NIX_CFLAGS_COMPILE = lib.optionals (stdenv.cc.isGNU && lib.versionAtLeast stdenv.cc.version "12") [
     # Needed with GCC 12 but breaks on darwin (with clang) or older gcc
     "-Wno-error=mismatched-new-delete"
   ];
diff --git a/pkgs/tools/text/sgml/jade/default.nix b/pkgs/tools/text/sgml/jade/default.nix
index 891e26017e68c..a744300bfddec 100644
--- a/pkgs/tools/text/sgml/jade/default.nix
+++ b/pkgs/tools/text/sgml/jade/default.nix
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ gnum4 ];
 
-  NIX_CFLAGS_COMPILE = "-Wno-deprecated";
+  env.NIX_CFLAGS_COMPILE = "-Wno-deprecated";
 
   # Makefile is missing intra-library depends, fails build as:
   # ld: cannot find -lsp
diff --git a/pkgs/tools/text/silver-searcher/default.nix b/pkgs/tools/text/silver-searcher/default.nix
index 53146ddd06105..94c5c8cf02fc9 100644
--- a/pkgs/tools/text/silver-searcher/default.nix
+++ b/pkgs/tools/text/silver-searcher/default.nix
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   #   ld: src/zfile.o:/build/source/src/log.h:12: multiple definition of
   #     `print_mtx'; src/ignore.o:/build/source/src/log.h:12: first defined here
   # TODO: remove once next release has https://github.com/ggreer/the_silver_searcher/pull/1377
-  NIX_CFLAGS_COMPILE = "-fcommon";
+  env.NIX_CFLAGS_COMPILE = "-fcommon";
   NIX_LDFLAGS = lib.optionalString stdenv.isLinux "-lgcc_s";
 
   nativeBuildInputs = [ autoreconfHook pkg-config ];
diff --git a/pkgs/tools/text/smu/default.nix b/pkgs/tools/text/smu/default.nix
index 02a29a91f47d9..85e593982e85a 100644
--- a/pkgs/tools/text/smu/default.nix
+++ b/pkgs/tools/text/smu/default.nix
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   };
 
   # _FORTIFY_SOURCE requires compiling with optimization (-O)
-  NIX_CFLAGS_COMPILE = "-O";
+  env.NIX_CFLAGS_COMPILE = "-O";
 
   makeFlags = [
     "PREFIX=${placeholder "out"}"