[Nix-dev] [Nix-commits] SVN commit: nix - r31643 - nixpkgs/branches/stdenv-updates/pkgs/tools/misc/coreutils

Peter Simons simons at cryp.to
Thu Jan 19 16:10:50 CET 2012


Hi Ludovic,

 >> +  NIX_LDFLAGS = stdenv.lib.optionalString selinuxSupport "-lsepol";
 >> +
 >>    meta = {
 >>      homepage = http://www.gnu.org/software/coreutils/;
 >>      description = "The basic file, shell and text manipulation utilities of the GNU operating system";
 >> @@ -58,5 +60,5 @@
 >>
 >>      maintainers = [ stdenv.lib.maintainers.ludo ];
 >>    };
 >> -} // (if selinuxSupport then { NIX_LDFLAGS = "-lsepol"; } else { } ) )
 >
 > Isn’t it redundant?

note the "minus" at the beginning of that last line.


 > Also, what about using $LDFLAGS instead?
 >
 >   $ ./configure --help | grep -C2 FLAGS
 >   Usage: ./configure [OPTION]... [VAR=VALUE]...
 >
 >   To assign environment variables (e.g., CC, CFLAGS...), specify them as
 >   VAR=VALUE.  See below for descriptions of some of the useful variables.
 >
 >   --
 >   Some influential environment variables:
 >     CC          C compiler command
 >     CFLAGS      C compiler flags
 >     LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
 >                 nonstandard directory <lib dir>
 >     LIBS        libraries to pass to the linker, e.g. -l<library>
 >     CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
 >                 you have headers in a nonstandard directory <include dir>
 >     CPP         C preprocessor

You mean $LIBS? Do coreutils compile correctly when that flag is moved
to $LIBS instead?

Take care,
Peter



More information about the nix-dev mailing list