Merge pull request #173172 from Artturin/deprecatestringconf

stdenv: start deprecating non-list configureFlags
This commit is contained in:
Sandro 2022-05-19 11:25:24 +02:00 committed by GitHub
commit ed58443645
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 7 additions and 7 deletions

View file

@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
strictDeps = true;
CXXFLAGS = "-std=c++11";
configureFlags = "--enable-liblilv --with-extra-cppflags=-Dnullptr=0";
configureFlags = [ "--enable-liblilv" "--with-extra-cppflags=-Dnullptr=0" ];
postPatch = ''
sed -i -e '

View file

@ -17,7 +17,7 @@ in
let alt-ergo-lib = ocamlPackages.buildDunePackage rec {
pname = "alt-ergo-lib";
inherit version src useDune2;
configureFlags = pname;
configureFlags = [ pname ];
nativeBuildInputs = [ which ];
buildInputs = with ocamlPackages; [ dune-configurator ];
propagatedBuildInputs = with ocamlPackages; [ num ocplib-simplex stdlib-shims zarith ];
@ -26,7 +26,7 @@ let alt-ergo-lib = ocamlPackages.buildDunePackage rec {
let alt-ergo-parsers = ocamlPackages.buildDunePackage rec {
pname = "alt-ergo-parsers";
inherit version src useDune2;
configureFlags = pname;
configureFlags = [ pname ];
nativeBuildInputs = [ which ocamlPackages.menhir ];
propagatedBuildInputs = [ alt-ergo-lib ] ++ (with ocamlPackages; [ camlzip psmt2-frontend ]);
}; in
@ -35,7 +35,7 @@ ocamlPackages.buildDunePackage {
inherit pname version src useDune2;
configureFlags = pname;
configureFlags = [ pname ];
nativeBuildInputs = [ which ocamlPackages.menhir ];
buildInputs = [ alt-ergo-parsers ocamlPackages.cmdliner ];

View file

@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
# build fails otherwise
enableParallelBuilding = false;
configureFlags = "--libdir=$(OCAMLFIND_DESTDIR)";
configureFlags = [ "--libdir=$(OCAMLFIND_DESTDIR)" ];
meta = {
homepage = "https://github.com/thierry-martinez/stdcompat";

View file

@ -331,8 +331,8 @@ else let
# This parameter is sometimes a string, sometimes null, and sometimes a list, yuck
configureFlags = let inherit (lib) optional elem; in
(/**/ if lib.isString configureFlags then [configureFlags]
else if configureFlags == null then []
(/**/ if lib.isString configureFlags then lib.warn "String 'configureFlags' is deprecated and will be removed in release 23.05. Please use a list of strings. Derivation name: ${derivationArg.name}, file: ${pos.file or "unknown file"}" [configureFlags]
else if configureFlags == null then lib.warn "Null 'configureFlags' is deprecated and will be removed in release 23.05. Please use a empty list instead '[]'. Derivation name: ${derivationArg.name}, file: ${pos.file or "unknown file"}" []
else configureFlags)
++ optional (elem "build" configurePlatforms) "--build=${stdenv.buildPlatform.config}"
++ optional (elem "host" configurePlatforms) "--host=${stdenv.hostPlatform.config}"