[Nix-dev] how to use stdenv

Bjørn Forsman bjorn.forsman at gmail.com
Wed Dec 31 12:19:02 CET 2014


On 31 December 2014 at 11:42, Ganesh Sittampalam <ganesh at earth.li> wrote:
> Hi,
>
> https://nixos.org/wiki/Howto_develop_software_on_nixos talks about
> including stdenv in a myEnvFun environment to get gcc etc.
>
> However gcc and a bunch of other standard build tools don't seem to be
> part of stdenv any more:
>
> https://github.com/NixOS/nixpkgs/commit/328f7a621e0e2c37159e4cdd86fa279417fa3b9e
>
> ["stdenv: Remove propagatedUserEnvPkgs
> Stdenv is not really intended as an installable package. Nowadays it's
> much better to use "nix-shell -p" to get a build environment."]
>
> Is that wiki page out of date now? Is there a new recommended way of
> getting the build tools into a myEnvFun environment now?

I can think of a couple of ways:

- include gcc etc. in buildInputs
- use nix-shell instead of myEnvFun (like the commit message suggests)

Best regards,
Bjørn Forsman


More information about the nix-dev mailing list