[Nix-dev] Re: Python.h

Ludovic Courtès ludo at gnu.org
Tue Jun 3 00:09:37 CEST 2008


Hi,

pjotr2008 at thebird.nl (Pjotr Prins) writes:

> When writing code I need to find Python.h. What is the best way of
> doing that in Nix (note: this is *not* to build a package).

For packages that (correctly) use Autoconf, you can pass `CPPFLAGS' and
`LDFLAGS' to the `configure' script, as in:

  $ CPPFLAGS="-I$HOME/.nix-profile/include" \
    LDFLAGS="-L$HOME/.nix-profile/lib" \
    ./configure ...

Otherwise, you can define $C_INCLUDE_PATH, which is honored by `cpp',
and $LIBRARY_PATH, which is honored by GCC at link-time.

There are also Nix-specific environment variables whose name I always
forget...

Thanks,
Ludovic.




More information about the nix-dev mailing list