about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2014-12-14 Merge branch 'cygwin-master' of https://github.com/ternaris/nixEelco Dolstra5-0/+5
2014-12-13 Better error messageEelco Dolstra1-1/+1
2014-12-12 Silence some warnings on GCC 4.9Eelco Dolstra4-7/+12
2014-12-12 Shut up a Valgrind warningEelco Dolstra1-1/+1
2014-12-12 Fix some memory leaksEelco Dolstra3-35/+27
2014-12-12 Ensure we're writing to stderr in the builderEelco Dolstra6-19/+21
http://hydra.nixos.org/build/17862041
2014-12-12 Don't abort if we get a signal while waiting for the pagerEelco Dolstra1-4/+8
2014-12-12 Get rid of unnecessary "interrupted by the user" message with -vvvEelco Dolstra1-0/+2
2014-12-12 Remove chatty messageEelco Dolstra1-2/+0
This broke building with "-vv", because the builder is not allowed to write to stderr at this point.
2014-12-12 DohEelco Dolstra2-3/+3
2014-12-12 Remove tabsEelco Dolstra1-5/+5
2014-12-12 Remove dead codeEelco Dolstra1-9/+0
2014-12-12 Remove canary stuffEelco Dolstra4-58/+0
2014-12-10 Provide default pagersEelco Dolstra1-3/+8
Borrowed from systemd.
2014-12-10 Don't do vfork in conjunction with setuidEelco Dolstra2-0/+5
2014-12-10 Use vforkEelco Dolstra3-11/+39
2014-12-10 Rename functionEelco Dolstra1-4/+4
2014-12-10 Don't wait for PID -1Eelco Dolstra1-1/+2
The pid field can be -1 if forking the substituter process failed.
2014-12-10 Revert "Use posix_spawn to run the pager"Eelco Dolstra3-39/+10
This reverts commit d34d2b2bbf784c0bb420a50905af25e02c6e4989.
2014-12-10 builtins.readFile: realise context associated with the pathShea Levy1-2/+6
2014-12-09 Explicitly include required C headersMarko Durkovic5-0/+5
2014-12-05 Define ‘environ’Eelco Dolstra1-0/+2
http://hydra.nixos.org/build/17690555
2014-12-05 Use posix_spawn to run the pagerEelco Dolstra3-10/+39
In low memory environments, "nix-env -qa" failed because the fork to run the pager hit the kernel's overcommit limits. Using posix_spawn gets around this. (Actually, you have to use posix_spawn with the undocumented POSIX_SPAWN_USEVFORK flag, otherwise it just uses fork/exec...)
2014-12-02 Make all ExternalValueBase functions constShea Levy4-15/+15
2014-12-02 Allow external code using libnixexpr to add typesShea Levy5-0/+108
Code that links to libnixexpr (e.g. plugins loaded with importNative, or nix-exec) may want to provide custom value types and operations on values of those types. For example, nix-exec is currently using sets where a custom IO value type would be more appropriate. This commit provides a generic hook for such types in the form of tExternal and the ExternalBase virtual class, which contains all functions necessary for libnixexpr's type-polymorphic functions (e.g. `showType`) to be implemented.
2014-11-25 Add a primop for regular expression pattern matchingEelco Dolstra3-5/+57
The function ‘builtins.match’ takes a POSIX extended regular expression and an arbitrary string. It returns ‘null’ if the string does not match the regular expression. Otherwise, it returns a list containing substring matches corresponding to parenthesis groups in the regex. The regex must match the entire string (i.e. there is an implied "^<pat>$" around the regex). For example: match "foo" "foobar" => null match "foo" "foo" => [] match "f(o+)(.*)" "foooobar" => ["oooo" "bar"] match "(.*/)?([^/]*)" "/dir/file.nix" => ["/dir/" "file.nix"] match "(.*/)?([^/]*)" "file.nix" => [null "file.nix"] The following example finds all regular files with extension .nix or .patch underneath the current directory: let findFiles = pat: dir: concatLists (mapAttrsToList (name: type: if type == "directory" then findFiles pat (dir + "/" + name) else if type == "regular" && match pat name != null then [(dir + "/" + name)] else []) (readDir dir)); in findFiles ".*\\.(nix|patch)" (toString ./.)
2014-11-25 forceString(): Accept pos argumentEelco Dolstra3-5/+5
2014-11-24 Build derivations in a more predictable orderEelco Dolstra1-7/+41
Derivations are now built in order of derivation name, so a package named "aardvark" is built before "baboon". Fixes #399.
2014-11-24 Don't create unnecessary substitution goals for derivationsEelco Dolstra1-0/+5
2014-11-20 import derivation: cleanupShea Levy1-8/+11
Before this there was a bug where a `find` was being called on a not-yet-sorted set. The code was just a mess before anyway, so I cleaned it up while fixing it.
2014-11-19 Disable vacuuming the DB after garbage collectionEelco Dolstra1-1/+1
Especially in WAL mode on a highly loaded machine, this is not a good idea because it results in a WAL file of approximately the same size ad the database, which apparently cannot be deleted while anybody is accessing it.
2014-11-19 nix-daemon: Call exit(), not _exit()Eelco Dolstra3-5/+8
This was preventing destructors from running. In particular, it was preventing the deletion of the temproot file for each worker process. It may also have been responsible for the excessive WAL growth on Hydra (due to the SQLite database not being closed properly). Apparently broken by accident in 8e9140cfdef9dbd1eb61e4c75c91d452ab5e4a74.
2014-11-19 Clean up temp roots in a more C++ wayEelco Dolstra3-26/+13
2014-11-17 Fix messageEelco Dolstra1-1/+1
2014-11-15 realiseContext: Handle all context typesShea Levy1-2/+2
Avoids an assertion
2014-11-15 Add functors (callable attribute sets).Shea Levy2-1/+13
With this, attribute sets with a `__functor` attribute can be applied just like normal functions. This can be used to attach arbitrary metadata to a function without callers needing to treat it specially.
2014-11-14 Don't use ADDR_LIMIT_3GBEelco Dolstra1-1/+1
This gives 32-bit builds on x86_64-linux more memory.
2014-11-12 Make ~DerivationGoal more reliableEelco Dolstra1-7/+3
2014-11-04 nix-store --gc: Don't warn about missing manifests directoryEelco Dolstra1-1/+2
2014-10-31 nix-daemon: Get peer credentials on Mac OS XEelco Dolstra1-19/+52
This makes allowed-users and trusted-users work on Mac OS X.
2014-10-31 Improve error message if the daemon worker fails to startEelco Dolstra2-3/+2
2014-10-31 Fix more warningsEelco Dolstra1-11/+1
2014-10-31 Shut up a clang warningEelco Dolstra1-1/+1
2014-10-29 Remove comments claiming we use a private PID namespaceEelco Dolstra1-8/+1
This is no longer the case since 524f89f1399724e596f61faba2c6861b1bb7b9c5.
2014-10-20 Fix build on gcc < 4.7Shea Levy2-0/+16
2014-10-20 Revert "Drop support for pre-c++11 compilers."Shea Levy1-1/+2
The breakage this fixed can be worked around without removing support. This reverts commit 84a13dc576496f1227665259c61f86184f452f51.
2014-10-20 Improve printing of ASTsEelco Dolstra3-16/+58
2014-10-18 Drop support for pre-c++11 compilers.Shea Levy1-2/+1
In particular, gcc 4.6's std::exception::~exception has an exception specification in c++0x mode, which requires us to use that deprecated feature in nix (and led to breakage after some recent changes that were valid c++11). nix already uses several c++11 features and gcc 4.7 has been around for over 2 years.
2014-10-17 Export realiseContext in libnixexprShea Levy2-9/+11
Useful for importNative plugins
2014-10-14 nix-store -q: Check for conflicting flagsEelco Dolstra1-4/+12
Fixes #364.