Commit Graph

162 Commits

Author SHA1 Message Date
Peter Simons
b08e12b37a Revert "Merge pull request #567 from MarcWeber/submit/cmake-improvement"
This reverts commit abc7591aaf3912d819401241d7d2339fb96441f3, reversing changes
made to 6b1ebeccf2c9d9e8f68d7e21a1e55b5d91577683, because they broke half the
packages in stdenv-updates: http://hydra.nixos.org/eval/927013 has further
details.
2013-06-17 10:19:15 +02:00
Marc Weber
f7ef08e5cd experimental/cmake-improvement
set CMAKE_LIBRARY_PATH, CMAKE_INCLUDE_PATH based on NIX_CFLAGS_COMPILE and
NIX_LDFLAGS so that cmake's find_library like functions find all the libraries
gcc knows about thanks to the gcc wrapper

This is particular useful with myEnvFun which then also sets those CMAKE_* env
variables.`

Because setup.sh has to change this causes many rebuilds - thus it should be
included in a stdenv-update like branch

Also cmake builds in parallel perfectly fine

update cmake to latest minor number, I didn't change the patches,
just reapplied them manually recordin a new patch
2013-05-28 16:22:45 +02:00
aszlig
82f94df719 stdenv/setup.sh: Always run postPatch hook.
I'm not sure whether this was by intention, but so far postPatch hooks were
silently skipped whenever the patches list was empty. This change could possibly
change the build results of the following packages:

 * gcc
 * cmake (264)
 * systemtap
 * quemu-kvm

These packages all have in common that they have a postPatch hook and the
patches list can be empty when certain conditions are met.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2013-02-27 15:26:18 +01:00
Eelco Dolstra
ab3eeabfed Rename buildNativeInputs -> nativeBuildInputs
Likewise for propagatedBuildNativeInputs, etc.  "buildNativeInputs"
sounds like an imperative rather than a noun phrase.
2012-12-28 19:20:09 +01:00
Eelco Dolstra
5be0a9acd7 Rename hostDrv -> crossDrv, buildDrv -> nativeDrv
This is for consistency with terminology in stdenv (and the terms
"hostDrv" and "buildDrv" are not very intuitive, even if they're
consistent with GNU terminology).
2012-12-28 19:08:19 +01:00
Eelco Dolstra
f4ed8a3b91 Remove trailing whitespace 2012-12-28 16:41:56 +01:00
Eelco Dolstra
cf8daf6312 Add an option ‘stdenv.userHook’ to set a global stdenv setup hook
This allows various applications.  It allows users to set global
optimisation flags, e.g.

  stdenv.userHook = ''NIX_CFLAGS_COMPILE+=" -funroll-loops"'';

But the impetus is as an alternative to issue #229, allowing impure
stdenv setup for people who want to use distcc:

  stdenv.userHook = "source /my/impure/setup-script.sh";

This is probably a bad idea, but at least now it's a bad idea in
people's configuration and not in Nixpkgs. :-)
2012-12-28 16:36:09 +01:00
Eelco Dolstra
6fd4f63530 Revert "Merge pull request #229 from viric/niximpure2-stdenv-updates"
This reverts commit e04b17bfbaa4dbd5252d59f727d7d84ffe25f568, reversing
changes made to 1af2ada7d4c61e79356a0f3f8bcced6159a6e751.
2012-12-28 15:46:45 +01:00
Lluís Batlle i Rossell
095db9fe3f stdenv: Stripping out/lib32 too
If not, in mips64/n32, lib32/libiberty.a was left without stripping, and
it contained (debug) references to bootstrap-tools.
2012-12-27 23:36:01 +01:00
Lluís Batlle i Rossell
635880a17a 2nd approach at getting a check for /niximpure in stdenv-updates 2012-12-26 21:38:58 +01:00
Shea Levy
6d928ab684 Don't preserve timestamps when copying sources to the temporary build directory.
This should fix issues like "ZIP does not support timestamps before 1980"
2012-12-14 13:36:04 -05:00
Eelco Dolstra
0008138201 checkPhase: Pass VERBOSE=y so that failing tests show something useful 2012-10-16 15:00:51 -04:00
Eelco Dolstra
b3d20690a1 For consistency, don't use the -v flag when copying a directory $src 2012-09-25 21:31:16 -04:00
Eelco Dolstra
be901fa8be * Add an installCheckPhase.
svn path=/nixpkgs/branches/stdenv-updates/; revision=33967
2012-05-01 21:00:30 +00:00
Shea Levy
6f711ceb01 Revert r33547
svn path=/nixpkgs/branches/stdenv-updates/; revision=33583
2012-04-04 19:45:01 +00:00
Shea Levy
358e51bb6d tar doesn't need -f - to read from stdin
svn path=/nixpkgs/branches/stdenv-updates/; revision=33574
2012-04-04 16:27:04 +00:00
Shea Levy
4a84fd30b5 Don't do verbose unpacking, it's just log noise
svn path=/nixpkgs/branches/stdenv-updates/; revision=33573
2012-04-04 16:25:17 +00:00
Shea Levy
483f094acb Honor propagatedUserEnvPackages in setup.sh
svn path=/nixpkgs/branches/stdenv-updates/; revision=32369
2012-02-17 21:37:15 +00:00
Eelco Dolstra
b27b5dfd75 * Doh.
svn path=/nixpkgs/branches/stdenv-updates/; revision=31726
2012-01-19 22:18:34 +00:00
Eelco Dolstra
61d0c5d931 * Don't rely on tar knowing about .xz.
svn path=/nixpkgs/branches/stdenv-updates/; revision=31708
2012-01-19 17:33:33 +00:00
Eelco Dolstra
698c4d296b * "test" -> "[ ... ]" (style cleanup).
svn path=/nixpkgs/branches/stdenv-updates/; revision=31704
2012-01-19 16:14:09 +00:00
Eelco Dolstra
ee45e160b1 * Prepend the "prehook" rather than sourcing it.
* Don't call xargs with the -r flag in the Darwin bootstrap.

svn path=/nixpkgs/branches/stdenv-updates/; revision=31703
2012-01-19 15:56:17 +00:00
Eelco Dolstra
6208059079 * The postHook substitution is not used anywhere, so get rid of it.
svn path=/nixpkgs/branches/stdenv-updates/; revision=31702
2012-01-19 15:39:12 +00:00
Eelco Dolstra
b31df26cea * Remove an unnecessary check.
svn path=/nixpkgs/branches/stdenv-updates/; revision=31701
2012-01-19 15:31:56 +00:00
Eelco Dolstra
0d71e75222 * Get rid of params1-5, they're obsolete.
svn path=/nixpkgs/branches/stdenv-updates/; revision=31700
2012-01-19 15:29:20 +00:00
Eelco Dolstra
0e6fa321bb * Don't use the "replace-literal" command in stdenv; instead use
bash's pattern replacement feature.  "replace-literal" is an
  uncommon command so it was a headache during the bootstrap.

svn path=/nixpkgs/branches/stdenv-updates/; revision=31681
2012-01-19 13:47:26 +00:00
Eelco Dolstra
fc89eefa50 * Seems that bash 3.2 on Mac OS X doesn't know the \e
escape, so use \033 instead.

svn path=/nixpkgs/branches/stdenv-updates/; revision=31680
2012-01-19 10:24:26 +00:00
Eelco Dolstra
c556a6ea46 * "ensureDir" -> "mkdir -p". "ensureDir" is a rather pointless
function, so obsolete it.

svn path=/nixpkgs/branches/stdenv-updates/; revision=31644
2012-01-18 20:16:00 +00:00
Eelco Dolstra
3ea1c30846 * Remove the NIX_STRIP_DEBUG flag. It was undocumented and confusing
in its interaction with the ‘dontStrip’ attribute.

svn path=/nixpkgs/branches/stdenv-updates/; revision=30848
2011-12-12 14:02:12 +00:00
Eelco Dolstra
fd394a7c4a * Only print "@ phase..." messages on demand since they're kind of
ugly and we already print phases (with start and end markers).
* Remove some stray tabs.

svn path=/nixpkgs/branches/stdenv-updates/; revision=30059
2011-10-27 16:32:46 +00:00
Shea Levy
1a43ce8e08 Add a substituteAllInPlace() function to stdenv
svn path=/nixpkgs/branches/stdenv-updates/; revision=27993
2011-07-28 20:28:37 +00:00
Lluís Batlle i Rossell
c06046e5ef Improving a bit the manpage gzip code. I decided to gzip hard links and soft
links, as nix-store --optimise can care better later.


svn path=/nixpkgs/branches/stdenv-updates/; revision=26242
2011-03-09 22:17:18 +00:00
Lluís Batlle i Rossell
65c78a3222 Adding a manpage gzipping stage in the fixupPhase. This should go unnoticed,
but for the less disk space used.


svn path=/nixpkgs/branches/stdenv-updates/; revision=26241
2011-03-09 20:10:47 +00:00
Ludovic Courtès
cff72e7a83 stdenv: Emit phase-started' and phase-succeeded' events.
These markers follow the format of those of `nix-store --print-build-trace',
which allows extraction of, say, phase durations in a similar way.

svn path=/nixpkgs/branches/stdenv-updates/; revision=26115
2011-02-25 15:28:11 +00:00
Lluís Batlle i Rossell
b724fa3d44 Adding support for the /lib32 (there was /lib and /lib64 only), for the n32 ABI in mips I'm
making the longsoon2f system for.

svn path=/nixpkgs/branches/stdenv-updates/; revision=23044
2010-08-08 18:53:00 +00:00
Peter Simons
226e0c7646 pkgs/stdenv/generic/setup.sh: added support for enableParallelBuilding variable
If a build expressions has set "enableParallelBuilding = true", then the
generic builder may utilize more than one CPU core to build that particular
expression. This feature works out of the box for GNU Make. Expressions that
use other build drivers like Boost.Jam or SCons have to specify appropriate
flags such as "-j${NIX_BUILD_CORES}" themselves.

svn path=/nixpkgs/branches/stdenv-updates/; revision=22399
2010-06-23 14:34:59 +00:00
Marc Weber
f3e7f0fdf0 reverting my patch series adding -j -l support for make
svn path=/nixpkgs/branches/stdenv-updates/; revision=22336
2010-06-19 15:52:28 +00:00
Marc Weber
f446814260 no longer pass -j to make without arg which means no limit on forks. This brought down the build farm
svn path=/nixpkgs/branches/stdenv-updates/; revision=22293
2010-06-16 12:39:19 +00:00
Marc Weber
3c14e712ca setup.sh: add -j and -l options
svn path=/nixpkgs/branches/stdenv-updates/; revision=22283
2010-06-15 19:00:51 +00:00
Marc Weber
4f1075c40b generic/setup.sh: remove duplication: - add generic showCommand function which prints a command before running it - add runMake which is using that function passing the makefile if set
make all make invokations use runMake

svn path=/nixpkgs/branches/stdenv-updates/; revision=22282
2010-06-15 19:00:48 +00:00
Eelco Dolstra
69434e0592 * Add support for lzma patches.
svn path=/nixpkgs/branches/stdenv-updates/; revision=19028
2009-12-18 11:26:36 +00:00
Lluís Batlle i Rossell
d8aa5b5db1 Fixing stdenv's chain of propagated-build-inputs (2nd level propagated build
inputs did not get in)
Updating the xorg builder script to support cross building (in fact, support
for propagating the required build inputs).


svn path=/nixpkgs/branches/stdenv-updates/; revision=18569
2009-11-23 19:45:18 +00:00
Lluís Batlle i Rossell
585ba8c27f Big fixes in the cross build:
- Before this changes, cflags and ldflags for the native and the cross compiler
  got mixed. Not all the gcc-wrapper/gcc-cross-wrapper variables are
  independant now, but enough, I think.
- Fixed the generic stdenv expression, which did a big mess on buildInputs and
  buildNativeInputs. Now it distinguishes when there is a stdenvCross or not.
  Maybe we should have a single stdenv and forget about the stdenvCross
  adapter - this could end in a stdenv a bit complex, but simpler than the
  generic stdenv + adapter.
- Added basic support in pkgconfig for cross-builds: a single PKG_CONFIG_PATH
  now works for both the cross and the native compilers, but I think this
  should work well for most cases I can think of.
- I tried to fix the guile expression to cross-biuld; guile is built, but not
  its manual, so the derivation still fails. Guile requires patching to
  cross-build, as far as I understnad.
- Made the glibcCross build to be done through the usage of a
  gcc-cross-wrapper over the gcc-cross-stage-static, instead of using it
  directly.
- Trying to make physfs (a neverball dependency) cross build.
- Updated the gcc expression to support building a cross compiler without getting
  derivation variables mixed with those of the stdenvCross.

svn path=/nixpkgs/branches/stdenv-updates/; revision=18534
2009-11-22 19:51:45 +00:00
Ludovic Courtès
ab61e5b40d stdenv: Let GNU tar select the decompression method.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18492
2009-11-20 17:10:00 +00:00
Lluís Batlle i Rossell
6f3630e128 Attention, people who care on the builders for native builds. In the stdenv
derivation, the "buildInputs" in every stdenv mkDerivation don't map now
directly to the environment
variable "buildInputs" in the builder, but "buildNativeInputs". So, the inputs
build by the native compiler.
When cross compiling, they will map to the environment variable "buildInputs"
(yes, now the same name), which means does to be built with the cross compiler.

I think I improved the naming of variables a bit. There was a big mess,
specially in the stdenv adapter for cross building, and also in the default
builder script.

I also tried to add proper manager of propagatedInputBuilds, these being
propagated considering the host or build origin of that input build (so, at the
end, being those propagatedInputBuilds being propagated properly to the native
or the cross compiler.


svn path=/nixpkgs/branches/stdenv-updates/; revision=18477
2009-11-19 23:05:11 +00:00
Nicolas Pierron
6ba27ab552 * Add file support in the runHook function.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18467
2009-11-19 17:19:32 +00:00
Lluís Batlle i Rossell
8c638e5e68 Fixing what I broke in the last commit in setup.sh.
I made the stdenvCross adapter simpler, according to Nicolas Pierron comments,
and I commented it a bit.

There are still jobs to do. At least:
- Plan for the general renaming from buildInputs to hostInputs
  - We should not break merges from trunk.
- Make the generic stdenv understand about host/buildInputs, at least for
  native builds, because it is used in the always-native building of
  stdenvLinux. This should allow us to remove all duplications of "*NoCross" in
  nixpkgs.


svn path=/nixpkgs/branches/stdenv-updates/; revision=18449
2009-11-18 19:25:57 +00:00
Lluís Batlle i Rossell
4c09cfc8a3 Adding generic builder management of cross compilation: envHooksHost, pkgsHost, ...
svn path=/nixpkgs/branches/stdenv-updates/; revision=18446
2009-11-18 18:16:35 +00:00
Lluís Batlle i Rossell
6675f0a52c Adding a check in the generic builder so it halts on the existence of
/homeless-shelter


svn path=/nixpkgs/branches/stdenv-updates/; revision=18302
2009-11-08 22:50:27 +00:00
Eelco Dolstra
ae03990f6a * setup-new -> setup.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16133
2009-07-02 09:01:37 +00:00
Eelco Dolstra
2a699fe5fb * Pass --disable-static to configure by default it it's supported.
svn path=/nixpkgs/branches/stdenv-updates/; revision=15234
2009-04-21 22:40:12 +00:00
Eelco Dolstra
6b9ccbaf78 * setup.sh: turn on nullglob globally.
* setup.sh: removed some obsolete features, specifically some that
  were only used by the old build farm.
* addToSearchPath: removed some parameters that weren't used
  anywhere.

svn path=/nixpkgs/branches/stdenv-updates/; revision=15136
2009-04-18 22:22:51 +00:00
Eelco Dolstra
d9213df2c1 * gcc-wrapper: put "gcc-wrapper" in the name, e.g. "gcc-wrapper-4.3.3"
instead of "gcc-4.3.3".  This fixed the long-standing annoyance that
  you can't distinguish the two in (say) nix-store -qR.
* On x86_64-linux, put $out/lib64 in the RPATH in addition to
  $out/lib, because some packages (in particular GCC) put libraries in
  $out/lib64 and ended up linking against the wrong library.
* Strip $out/lib64.
* Removed g77_42 because it's exactly the same as gfortran.

svn path=/nixpkgs/branches/stdenv-updates/; revision=14708
2009-03-25 17:34:38 +00:00
Eelco Dolstra
12038d5586 * Allow hooks like preBuild to be set both through shell functions and
variables.  This is so you don't have to write things like

    preBuild=preBuild
    preBuild() {
      bla
    }

svn path=/nixpkgs/branches/stdenv-updates/; revision=13941
2009-02-01 21:28:02 +00:00
Eelco Dolstra
63246c648f * Turn on Make indentation.
svn path=/nixpkgs/branches/stdenv-updates/; revision=13810
2009-01-19 20:31:02 +00:00
Eelco Dolstra
0adab29d1e svn path=/nixpkgs/branches/stdenv-updates/; revision=13603 2008-12-10 10:21:05 +00:00
Eelco Dolstra
cdc74e1677 svn path=/nixpkgs/branches/stdenv-updates/; revision=13602 2008-12-10 10:12:32 +00:00
Eelco Dolstra
903ca0fc40 * Do the right thing if $sourceRoot contains spaces. Contributed by
Jeevakan Suresh.

svn path=/nixpkgs/branches/stdenv-updates/; revision=13287
2008-11-14 10:22:15 +00:00
Eelco Dolstra
9a3890592d * Missing space.
svn path=/nixpkgs/branches/stdenv-updates/; revision=13163
2008-10-30 15:54:29 +00:00
Eelco Dolstra
69b538fde3 * gcc-wrapper-new -> gcc-wrapper, setup-new -> setup.
svn path=/nixpkgs/branches/stdenv-updates/; revision=12991
2008-10-07 17:33:20 +00:00
Eelco Dolstra
8f9baa2e5a * Darwin compatibility.
svn path=/nixpkgs/branches/stdenv-updates/; revision=12038
2008-06-11 14:08:01 +00:00
Eelco Dolstra
1000662377 * Automatically patch shebang paths ("#! /interpreter") to store
paths.  E.g. /usr/bin/perl is rewritten to /nix/store/<whatever Perl
  is in $PATH>.  Paths in the Nix store are left unchanged.
  Contributed by Nicolas Pierron.

svn path=/nixpkgs/branches/stdenv-updates/; revision=12036
2008-06-11 11:22:54 +00:00
Eelco Dolstra
16f2d8b2d5 * Implement the succeedOnFailure flag by trapping EXIT. This makes
the fail() function unnecessary.
* Flag showBuildStats to print execution times on builder exit.

svn path=/nixpkgs/branches/stdenv-updates/; revision=11688
2008-04-23 07:19:48 +00:00
Eelco Dolstra
4195c1522f * Some variables to make it easier to inject additional phases.
svn path=/nixpkgs/branches/stdenv-updates/; revision=11221
2008-03-20 10:59:47 +00:00
Eelco Dolstra
9bddb8a172 * stripDirs: nest the output.
svn path=/nixpkgs/branches/stdenv-updates/; revision=11220
2008-03-20 10:54:58 +00:00
Eelco Dolstra
c0c199dbc7 * Add some missing pre/post hooks.
svn path=/nixpkgs/branches/stdenv-updates/; revision=11179
2008-03-18 11:03:35 +00:00
Eelco Dolstra
68d08cd70d * fixupPhase: don't barf if the output doesn't exist yet.
svn path=/nixpkgs/branches/stdenv-updates/; revision=11177
2008-03-18 10:28:17 +00:00
Eelco Dolstra
aaeed176c5 * Oops, don't pass --prefix twice.
svn path=/nixpkgs/branches/stdenv-updates/; revision=11176
2008-03-18 10:26:43 +00:00
Eelco Dolstra
2e92cabb37 * substitute: support patterns starting with a dash.
* Updated the kernel headers.
* ghc: setup hooks are now generated using substituteAll.

svn path=/nixpkgs/branches/stdenv-updates-merge/; revision=10838
2008-02-22 18:19:04 +00:00
Eelco Dolstra
a62b2564ba * Merge the makeFlags check.
svn path=/nixpkgs/branches/stdenv-updates-merge/; revision=10810
2008-02-21 16:23:47 +00:00
Eelco Dolstra
e7570bb9cf * Don't strip all symbols from $out/bin by default, since it makes
stack traces impossible.
* When stripping all symbols on Darwin, don't use the "-s" flag
  since it has a completely different meaning (it takes an argument 
  specifying a file containing a list of symbols).

svn path=/nixpkgs/branches/stdenv-updates-merge/; revision=10809
2008-02-21 16:20:51 +00:00
Michael Raskin
ed3cf0a497 Fixed setup.sh - non-default Makefile may be passed in makeFlags. OpenFire added, doesn't work yet
svn path=/nixpkgs/branches/stdenv-updates/; revision=10795
2008-02-21 04:48:55 +00:00
Eelco Dolstra
e12b421add * Merged most of the stdenv-updates branch. Some stuff didn't
merge cleanly right away (kde-4, kernel stuff) so it should be
  merged later.  But the stdenv stuff is all there.

svn path=/nixpkgs/branches/stdenv-updates-merge/; revision=10793
2008-02-20 23:02:41 +00:00
Eelco Dolstra
39c3cd4259 * Get rid of all the phase wrapper functions, just do that generically
in genericBuild.  This also means that you can override a phase
  function by redefining it, like

    buildPhase() {
      ... do something ...
    }

  and you still get the log nesting stuff.

* GNUmakefile is also a valid makefile name.

* Evaluate the variables $preHook and $postHook to allow more stdenv
  overrideability.

svn path=/nixpkgs/branches/stdenv-updates/; revision=10786
2008-02-20 17:10:36 +00:00
Eelco Dolstra
0ebff4e1d0 * buildPhase: skip if there is no Makefile (just like configurePhase
is skipped when there is no configure script).  So you don't need to
  set

    buildPhase = "true";

  for derivations that don't have any build action.

* Variable $makefile to allow the makefile to be specified.

svn path=/nixpkgs/branches/stdenv-updates/; revision=10784
2008-02-20 15:16:48 +00:00
Michael Raskin
2a087141cb Ported replace renaming to replace-literal to avoid conflict with MySQL package supplying own tool with name replace.
svn path=/nixpkgs/branches/stdenv-updates/; revision=10704
2008-02-15 11:14:40 +00:00
Eelco Dolstra
908d8286ce * Add --disable-dependency-tracking to the configure flags if
possible.  This should speed up builds a bit.  (Suggested by Ludovic
  Courtès.)

svn path=/nixpkgs/branches/stdenv-updates/; revision=10662
2008-02-13 18:27:19 +00:00
Eelco Dolstra
5f45fb3ae9 * substitute() in stdenv: use the replace program instead of awful
sed hackery.
* Some indentation fixes in setup.sh.

svn path=/nixpkgs/branches/stdenv-updates/; revision=10658
2008-02-13 14:23:09 +00:00
Eelco Dolstra
ff95bc3eea * Use gzip -d / bzip2 -d instead of gunzip / bunzip2.
svn path=/nixpkgs/branches/stdenv-updates/; revision=9839
2007-12-03 17:55:41 +00:00
Yury G. Kudryashov
f2b2932ee2 Spacing in setup.sh
svn path=/nixpkgs/branches/stdenv-updates/; revision=9738
2007-11-17 14:34:49 +00:00
Yury G. Kudryashov
51a3cde784 Now all the files setup-new-2.sh, setup-new.sh and setup.sh are the same file.
svn path=/nixpkgs/branches/stdenv-updates/; revision=9736
2007-11-17 14:34:27 +00:00
Eelco Dolstra
210f4950ac * Merge setup-new.sh.
svn path=/nixpkgs/trunk/; revision=8757
2007-05-24 15:29:32 +00:00
Eelco Dolstra
1d4d77179c * Always set the prefix.
svn path=/nixpkgs/trunk/; revision=7513
2006-12-28 21:12:44 +00:00
Eelco Dolstra
98e5779a9b * Don't clobber $shell.
svn path=/nixpkgs/trunk/; revision=7512
2006-12-28 11:32:20 +00:00
Eelco Dolstra
bb9f4a2280 * Workaround a bug in older versions of bash.
svn path=/nixpkgs/trunk/; revision=7511
2006-12-28 11:15:12 +00:00
Eelco Dolstra
138c0ae751 * Merge the new generic builder.
* Removed substitute, it's part of the generic builder now.
* stdenv-initial (Linux): use the real generic builder script.  This
  does require that sed is in the path of the builder of the initial
  stdenv.

svn path=/nixpkgs/trunk/; revision=7498
2006-12-27 18:14:57 +00:00
Eelco Dolstra
0b7e256162 * Hook variables in the generic builder are now executed using eval.
This has a major advantage: you can write hooks directly in Nix
  expressions.  For instance, rather than write a builder like this:

    source $stdenv/setup

    postInstall=postInstall
    postInstall() {
        ln -sf gzip $out/bin/gunzip
        ln -sf gzip $out/bin/zcat
    }

    genericBuild

  (the gzip builder), you can just add this attribute to the
  derivation:

    postInstall = "ln -sf gzip $out/bin/gunzip; ln -sf gzip $out/bin/zcat";

  and so a separate build script becomes unnecessary.  This should
  allow us to get rid of most builders in Nixpkgs.

* Allow configure and make arguments to contain whitespace.
  Previously, you could say, for instance

    configureFlags="CFLAGS=-O0"

  but not

    configureFlags="CFLAGS=-O0 -g"

  since the `-g' would be interpreted as a separate argument to
  configure.  Now you can say

    configureFlagsArray=("CFLAGS=-O0 -g")

  or similarly

    configureFlagsArray=("CFLAGS=-O0 -g" "LDFLAGS=-L/foo -L/bar")

  which does the right thing.  Idem for makeFlags, installFlags,
  checkFlags and distFlags.

  Unfortunately you can't pass arrays to Bash through the environment,
  so you can't put the array above in a Nix expression, e.g.,

    configureFlagsArray = ["CFLAGS=-O0 -g"];

  since it would just be flattened to a since string.  However, you
  can use the inline hooks described above:

    preConfigure = "configureFlagsArray=(\"CFLAGS=-O0 -g\")";


svn path=/nixpkgs/trunk/; revision=6863
2006-10-26 22:20:25 +00:00
Eelco Dolstra
0617704deb * Step 2. Too bad we can't replace files atomically in SVN!
svn path=/nixpkgs/trunk/; revision=6315
2006-08-29 18:07:52 +00:00
Eelco Dolstra
5df13f87f4 * Step 1...
svn path=/nixpkgs/trunk/; revision=6314
2006-08-29 18:07:33 +00:00
Eelco Dolstra
82e678362f * "." -> "source".
svn path=/nixpkgs/trunk/; revision=4335
2005-12-05 14:11:09 +00:00
Eelco Dolstra
552de99c19 * Update a bunch of base packages.
svn path=/nixpkgs/trunk/; revision=4065
2005-10-11 14:29:30 +00:00
Eelco Dolstra
0a2f531aea * Don't patch symlinked shared libraries.
svn path=/nixpkgs/trunk/; revision=3195
2005-06-17 13:46:04 +00:00
Eelco Dolstra
32d7a746a2 * Move ensureDir() up, otherwise calls to fail() might fail.
svn path=/nixpkgs/trunk/; revision=3192
2005-06-17 11:42:53 +00:00
Eelco Dolstra
6b8a8c92da * Fix regexp to match base-32 hashes.
svn path=/nixpkgs/trunk/; revision=2375
2005-03-10 17:32:09 +00:00
Eelco Dolstra
12c0a6351d * Use --strip-debug', not --strip-all', so that we can at least get
proper backtraces.  Otherwise debugging of Nix binaries is very
  hard.

svn path=/nixpkgs/trunk/; revision=2292
2005-02-23 22:01:54 +00:00
Eelco Dolstra
afc8ae625f * Make it possible to override the log writer (from its default,
`tee').  Useful in the build farm where we want to write logs
  through `bzip2'.

svn path=/nixpkgs/trunk/; revision=2270
2005-02-22 15:03:24 +00:00
Eelco Dolstra
b6001eed67 * Use patchelf to remove unnecessary directories automatically (in the
installation phase) from the rpaths of ELF executables and
  libraries.  This results in smaller closures.

svn path=/nixpkgs/trunk/; revision=1534
2004-10-02 18:27:50 +00:00
Eelco Dolstra
1ab4a9324c * The `patch' command is now part of stdenv, so it no longer needs to
be passed to derivations that need to apply patches.
* GCC 3.4 is now the default compiler (old GCC renamed to `gcc-3.3').
* The temporary GCCs built during the stdenvLinux bootstrap are now
  built without C++ support and without profiling.
* Remove fixincl in GCC 3.4 to prevent a retained dependency on the
  previous GCC.
* Always set $prefix in setup.sh, even when there is no configure
  script.

svn path=/nixpkgs/trunk/; revision=1444
2004-09-18 17:23:18 +00:00
Eelco Dolstra
286932e6b3 * Replace stdenv-generic with its branch (step 1).
svn path=/nixpkgs/trunk/; revision=1422
2004-09-17 12:35:57 +00:00
Eelco Dolstra
1550034ac4 * Various bug fixes in setup.sh and ld-wrapper.sh.
svn path=/nixpkgs/trunk/; revision=909
2004-04-02 17:49:44 +00:00