Eelco Dolstra
7482349fe8
* Implemented attribute set pattern matches.
2010-03-24 23:40:00 +00:00
Eelco Dolstra
0fd3648d34
* Store values in environments.
2010-03-24 12:41:08 +00:00
Eelco Dolstra
b70bd8fe56
* Reduce the number of value allocations in eval() by moving
...
responsibility for allocation of the result to the caller.
2010-03-24 12:11:38 +00:00
Eelco Dolstra
d31c59eb17
* Plain lambdas.
2010-03-24 11:06:05 +00:00
Eelco Dolstra
e8f7978274
2010-03-23 19:19:52 +00:00
Eelco Dolstra
0910ae9568
* Start of an evaluator that uses call-by-need (with thunk updating)
...
instead of (memoised) call-by-name.
2010-03-23 17:30:50 +00:00
Eelco Dolstra
141294ff38
* Clean up error messages in killUser().
2010-03-19 11:36:34 +00:00
Eelco Dolstra
f0c473c5f7
* Fix building on Cygwin ( http://hydra.nixos.org/build/325071 ).
2010-03-16 13:01:52 +00:00
Nicolas Pierron
741b7577c1
Merge r20344 & r20346.
2010-03-14 11:58:07 +00:00
Lluís Batlle i Rossell
2fb0df83e9
Uh. somehow a Makefile tab got in as spaces. Fixing.
2010-03-11 21:22:52 +00:00
Lluís Batlle i Rossell
13cce8ec45
Making 'bin2c' to be built with the compiler for the local system.
...
I copied the configure.ac code about CC_FOR_BUILD from libX11.
2010-03-11 20:56:25 +00:00
Ludovic Courtès
05e15049a5
Show the build user's group in /etc/group in chroots.
...
* src/libstore/build.cc (nix::DerivationGoal::startBuilder): Create
/etc/group showing the build user's group.
2010-03-11 14:47:04 +00:00
Ludovic Courtès
c752c9f41a
Fix thinko in r20547.
...
* src/libstore/build.cc (nix::DerivationGoal::startBuilder): Fix the GID
of the build user in /etc/passwd.
2010-03-11 10:33:04 +00:00
Ludovic Courtès
2e8eaca573
Clear supplementary groups of `nixbld' in /etc/passwd in chroots.
...
* src/libstore/build.cc (nix::DerivationGoal::startBuilder): Don't
display any supplementary groups for `nixbld' in /etc/passwd.
2010-03-11 10:21:23 +00:00
Eelco Dolstra
84a4dd5ff0
* Don't use fdatasync since it doesn't work on Snow Leopard.
...
* Don't refer to config.h in util.hh, because config.h is not
installed (http://hydra.nixos.org/build/303053 ).
2010-02-24 15:46:06 +00:00
Ludovic Courtès
20186a4079
Don't rely on `PATH_MAX' on GNU.
2010-02-10 15:55:50 +00:00
Eelco Dolstra
4e17be7981
* Revert r19797, and use a simpler solution: just don't monitor build
...
hooks for silence. It's unnecessary because the remote nix-store
command is already monitoring the real build.
2010-02-03 21:38:41 +00:00
Eelco Dolstra
f859a8d3c3
* While waiting for a lock, print a sign of life every 5 minutes.
...
This prevents remote builders from being killed by the
`max-silent-time' inactivity monitor while they are waiting for a
long garbage collection to finish. This happens fairly often in the
Hydra build farm.
2010-02-03 21:22:57 +00:00
Eelco Dolstra
4bbbe25802
* Remove most Cygwin-specific code. Cygwin 1.7 implements advisory
...
POSIX locks, and simulates Unix-style file deletion semantics
sufficiently. Note that this means that Nix won't work on Cygwin
1.5 anymore.
2010-02-02 15:28:36 +00:00
Eelco Dolstra
2723d9b56e
* If fdatasync() isn't available, use fsync().
2010-02-02 11:57:49 +00:00
Eelco Dolstra
07ffdc2862
* Added an option "fsync-metadata" to fsync() changes to
...
/nix/var/nix/db.
* Removed the function writeStringToFile since it does (almost) the
same thing as writeFile.
2010-01-29 12:22:58 +00:00
Eelco Dolstra
ad529fb89f
* Don't consider a store path valid if its info file exists but is
...
zero bytes long. That makes Nix more robust in case of crashes
(especially on ext4).
2010-01-29 11:53:58 +00:00
Eelco Dolstra
fdcaf37361
* Made `nix-store -qR --include-outputs' much faster if there are
...
multiple paths specified on the command line (from O(n * m) to O(n +
m), where n is the number of arguments and m is the size of the
closure).
2010-01-25 17:18:44 +00:00
Eelco Dolstra
5388944e8d
* Make the garbage collector do the right thing when `gc-keep-outputs'
...
is enabled by not depending on the deriver.
2010-01-25 16:04:32 +00:00
Eelco Dolstra
f0c0277970
* On startup, set the default SIGCHLD handler. This is so that Nix
...
works correctly in weird environments where the SIGCHLD handler is
set to "ignore".
2010-01-12 12:22:38 +00:00
Eelco Dolstra
ef92a14bfe
* Include config.h before the C library headers, because it defines
...
_FILE_OFFSET_BITS=64. Without it, functions like stat() fail on
large file sizes. This happened with a Nix store on squashfs:
$ nix-store --dump /tmp/mnt/46wzqnk4cbdwh1dclhrpqnnz1icak6n7-local-net-cmds > /dev/null
error: getting attributes of path `/tmp/mnt/46wzqnk4cbdwh1dclhrpqnnz1icak6n7-local-net-cmds': Value too large for defined data type
$ stat /tmp/mnt/46wzqnk4cbdwh1dclhrpqnnz1icak6n7-local-net-cmds
File: `/tmp/mnt/46wzqnk4cbdwh1dclhrpqnnz1icak6n7-local-net-cmds'
Size: 0 Blocks: 36028797018963968 IO Block: 1024 regular empty file
(This is a bug in squashfs or mksquashfs, but it shouldn't cause Nix
to fail.)
2009-12-17 14:12:44 +00:00
Eelco Dolstra
945d8218fb
* Build correctly against newer ATerm releases. Fixes "error: 'union'
...
tag used in naming 'struct _ATerm'".
2009-12-16 15:29:50 +00:00
Eelco Dolstra
bcd6cdf0d8
* Give a better error message when trying to build something and
...
readOnlyMode is set.
2009-12-09 17:45:22 +00:00
Eelco Dolstra
13618b191e
* Grrr.
2009-11-24 13:28:46 +00:00
Eelco Dolstra
aa5a768720
* GCC 4.4 is stricter about the EOF macro
...
(http://hydra.nixos.org/build/156340 ).
2009-11-24 12:56:26 +00:00
Eelco Dolstra
9b8fda796b
* Templatise getIntArg / string2Int.
2009-11-24 12:26:25 +00:00
Eelco Dolstra
8022015552
* In the garbage collector, don't count files with a link count > 1 in
...
the "bytes/blocks freed" statistics.
2009-11-24 10:51:52 +00:00
Eelco Dolstra
f9e766db98
* Randomise the order in which we delete entries to make the collector
...
less biased towards deleting paths that come alphabetically first
(e.g. /nix/store/000...). This matters when using --max-freed etc.
2009-11-24 09:53:18 +00:00
Eelco Dolstra
ca50c83fbb
2009-11-23 21:21:29 +00:00
Eelco Dolstra
3d55f1eb57
* A command `nix-store --query --roots <paths>' to find the garbage
...
collector roots that point (directly or indirectly) to the given
paths.
2009-11-23 18:16:25 +00:00
Eelco Dolstra
ae6bf87273
* `nix-store --gc --print-roots': also print the path of the actual
...
root symlink, not just its target. E.g.:
/nix/var/nix/profiles/system-99-link -> /nix/store/76kwf88657nq7wgk1hx3l1z5q91zb9wd-system
2009-11-23 17:23:12 +00:00
Eelco Dolstra
c364d5d1e3
* Made the garbage collector a lot faster. It no longer computes the
...
complete set of live and dead paths before starting the actual
deletion, but determines liveness on demand. I.e. for any path in
the store, it first tries to delete all the referrers, and then the
path itself. This means that the collector can start deleting paths
almost immediately.
2009-11-23 16:34:24 +00:00
Eelco Dolstra
8824d60fe5
* Remove the --use-atime / --max-atime garbage collector flags. Many
...
(Linux) machines no longer maintain the atime because it's too
expensive, and on the machines where --use-atime is useful (like the
buildfarm), reading the atimes on the entire Nix store takes way too
much time to make it practical.
2009-11-20 17:12:38 +00:00
Eelco Dolstra
327a232c85
* Remove support for old (before Nix 0.12pre12020) databases.
2009-11-06 01:15:44 +00:00
Eelco Dolstra
8520542071
* When building in a chroot, make a copy of a file if hard-linking
...
fails. This is likely to happen after a `nix-store --optimise',
because some files may have 32000 links (NIX-111).
2009-10-22 08:28:33 +00:00
Eelco Dolstra
6b9f6b0222
* Remove a prototype for a function that no longer exists.
2009-10-22 08:12:38 +00:00
Eelco Dolstra
deb342fb08
* builtins.trace: in the common case that the value is a string, then
...
show the string, not the ATerm, so we get `trace: bla' instead of
`trace: Str("bla",[])'.
2009-10-22 08:10:12 +00:00
Eelco Dolstra
437077c39d
* Added a primop unsafeDiscardOutputDependency needed by Disnix to
...
pass derivation paths to a builder without actually building them.
2009-10-21 15:05:30 +00:00
Eelco Dolstra
6f7d7bc1de
* Give a useful error message when an evaluation error occurs while
...
trying to upgrade a package.
2009-10-13 09:30:17 +00:00
Sander van der Burg
53a4981fa2
Added optional parameter which adds -lnsl -lsocket to make the Nix package manager work on OpenSolaris
2009-10-08 14:50:37 +00:00
Eelco Dolstra
96f1517831
* Support platforms that don't have O_ASYNC (e.g. OpenSolaris
...
apparently).
2009-09-30 11:32:04 +00:00
Eelco Dolstra
1a8f8fd86f
* OpenSolaris compatibility.
2009-09-30 09:54:29 +00:00
Eelco Dolstra
c7057fc1f2
* And some more.
2009-09-24 07:39:55 +00:00
Eelco Dolstra
193f59e077
* Fix a build failure on Fedora 11. rename() needs <stdio.h>.
2009-09-24 07:21:29 +00:00
Eelco Dolstra
1332dd1ed3
* tryEval shouldn't catch all exceptions of type Error, since not all
...
of them leave the evaluator in a continuable state. Also, it should
be less chatty.
2009-09-23 19:19:26 +00:00