Commit graph

11132 commits

Author SHA1 Message Date
Eelco Dolstra e6363b05ae * Pass $(prefix) and other variables through -D..., not
through config.h, to prevent silly Autoconf problems.
2003-07-13 19:26:00 +00:00
Eelco Dolstra 9c620e4afa * Generate the scripts so that we can substitute the prefix
etc. correctly.
* Fixed nix-switch.
2003-07-13 18:58:03 +00:00
Eelco Dolstra 5304a1eb3a * Fetchurl: check md5 checksum. 2003-07-12 11:03:14 +00:00
Eelco Dolstra 73b163c1a1 * Fix a bug that caused Fix not to be deterministic (due to addToStore
returning different paths if the hash of the path to be added was
  already available in the store under a different name).
2003-07-11 08:41:03 +00:00
Eelco Dolstra c834a5c597 * Fix handling of pipes (read(2) may not return the required
number of bytes in one call).
2003-07-11 08:16:15 +00:00
Eelco Dolstra 822c072cfa * Compress Nix archives when pushing them. 2003-07-10 20:34:29 +00:00
Eelco Dolstra 9bcc31c941 * Working derivate sharing. 2003-07-10 20:13:32 +00:00
Eelco Dolstra 81304a6bb5 * Convert tabs to spaces. 2003-07-10 19:27:46 +00:00
Eelco Dolstra e5fbf58041 * A command to register successor fstate expressions.
Unifying substitutes and successors isn't very feasible for now,
  since substitutes are only used when no path with a certain is
  known.  Therefore, a normal form of some expression stored as a
  substitute would not be used unless the expression itself was
  missing.
2003-07-10 18:48:11 +00:00
Eelco Dolstra 8511571f65 * Performance enhancement. 2003-07-10 15:24:50 +00:00
Eelco Dolstra 1d1c3691d2 * The policy-free derivate sharing now *almost* works. :-) For any
hash for which no local expansion is available, Nix can execute a
  `substitute' which should produce a path with such a hash.

  This is policy-free since Nix does not in any way specify how the
  substitute should work, i.e., it's an arbitrary (unnormalised)
  fstate expression.  For example, `nix-pull' registers substitutes
  that fetch Nix archives from the network (through `wget') and unpack
  them, but any other method is possible as well.  This is an
  improvement over the old Nix sharing scheme, which had a policy
  (fetching through `wget') built in.

  The sharing scheme doesn't work completely yet because successors
  from fstate rewriting have to be registered on the receiving side.
  Probably the whole successor stuff can be folded up into the
  substitute mechanism; this would be a nice simplification.
2003-07-10 15:11:48 +00:00
Eelco Dolstra d072485d28 * Get `nix-push' working again. It now uses Nix/Fix to create Nix
archives (using the package in corepkgs/nar).
* queryPathByHash -> expandHash, and it takes an argument specifying
  the target path (which may be empty).
* Install the core Fix packages in $prefix/share/fix.  TODO: bootstrap
  Nix and install Nix as a Fix package.
2003-07-10 13:41:28 +00:00
Eelco Dolstra 5d4b90b689 * Actually go through the search directories when looking for files. 2003-07-10 09:21:40 +00:00
Eelco Dolstra 089b436175 * Deleted the sys directory. 2003-07-10 09:12:52 +00:00
Eelco Dolstra b96239c657 * Moved the fetchutl package to corepkgs. 2003-07-10 09:11:30 +00:00
Eelco Dolstra 9ebd78144a * Added a directory for standard Fix descriptors. 2003-07-10 09:09:48 +00:00
Eelco Dolstra 6011bd0da2 * Outline of the new scheme for derivate distribution. 2003-07-09 16:12:40 +00:00
Eelco Dolstra 2b95a9dc05 * When computing the set of paths referenced by an expression, also
include the paths of the subterms.
2003-07-09 15:02:03 +00:00
Eelco Dolstra 9a99dc736d * Canonicalise paths so that Fix produces identical Nix
expressions for identical inputs.
2003-07-08 20:26:22 +00:00
Eelco Dolstra cab3f4977a * A path canonicaliser that doesn't depend on the existence of paths
(i.e., it doesn't use realpath(3), which is broken in any case).
  Therefore it doesn't resolve symlinks.
2003-07-08 19:58:41 +00:00
Eelco Dolstra 333f4963de * The output of a Derive() node is not a referenced path. 2003-07-08 15:33:06 +00:00
Eelco Dolstra 40274c1f4f * A command to query the paths referenced by an fstate expression.
* Use a temporary directory for build actions.
2003-07-08 13:22:08 +00:00
Eelco Dolstra a279137327 * Get --dump' and --delete' to work again. 2003-07-08 10:00:46 +00:00
Eelco Dolstra 85a913a3e7 * Renamed id' -> name' to remove the implication of uniqueness. 2003-07-08 09:59:00 +00:00
Eelco Dolstra 0b38b43bab * deletePath() now removes the path from the hash2paths mapping. 2003-07-08 09:54:47 +00:00
Eelco Dolstra ab644ad10b * BaseName() primitive for the generation of more sensible names
(especially in fetchurl.fix).
2003-07-08 09:53:46 +00:00
Eelco Dolstra a5a90f501e * Get rid of the `netsources' database.
* Rename the `refs' database to `hash2paths'.
2003-07-08 08:35:06 +00:00
Eelco Dolstra be96c2189c * --realise' -> --install'. 2003-07-07 09:29:40 +00:00
Eelco Dolstra 5895c160c4 * Make dbRefs a mapping from Hash to [Path]. 2003-07-07 09:25:26 +00:00
Eelco Dolstra 609a224848 * Fixed `make check' as well. 2003-07-07 07:44:57 +00:00
Eelco Dolstra 224c585aba * Refactoring on the file names. 2003-07-07 07:43:58 +00:00
Eelco Dolstra 7952a8053c * A utility `nix-hash' to compute Nix path hashes. 2003-07-06 15:11:02 +00:00
Eelco Dolstra bfa5d77211 * Bug fix: properly check result of open(). 2003-07-06 15:08:39 +00:00
Eelco Dolstra 82e3d8fafe * Got Fix working again. 2003-07-06 14:20:47 +00:00
Eelco Dolstra f826e432aa * Refactoring: move initialisation and argument parsing into a shared
file.
2003-07-04 15:42:03 +00:00
Eelco Dolstra 01b34fe584 * Cleanup. 2003-07-04 15:29:58 +00:00
Eelco Dolstra 207ff2caf0 * Caching of expression successors. 2003-07-04 12:18:06 +00:00
Eelco Dolstra 40b5936691 * Realisation of Derive(...) expressions. 2003-06-27 14:56:12 +00:00
Eelco Dolstra 3da9687854 * Realisation of File(...) expressions. 2003-06-27 13:55:12 +00:00
Eelco Dolstra bb03c45ca0 * Added the Boost format library which provides a safe printf
replacement.
2003-06-27 13:41:42 +00:00
Eelco Dolstra d4c3edfaba * Normalisation. 2003-06-27 09:55:31 +00:00
Eelco Dolstra 3ec5252582 * Improved syntax and semantics for Nix expressions. 2003-06-25 15:50:37 +00:00
Eelco Dolstra 2b07b0e7eb * Minor cleanups. 2003-06-25 14:58:56 +00:00
Eelco Dolstra 692b562342 * `nix --delete' command. 2003-06-23 14:40:49 +00:00
Eelco Dolstra c0cbaef4be * `nix --restore' command. 2003-06-23 14:08:34 +00:00
Eelco Dolstra 5f5cab0ac7 * A function to restore from a Nix archive.
* addValue() can now import any dumpable FS object.
2003-06-23 13:27:59 +00:00
Eelco Dolstra 85effedca3 * Flags to indicate how values are specified on the command line
(--hash, --file, --name).
2003-06-20 14:11:31 +00:00
Eelco Dolstra 5079ccb455 * Move most of Nix into a library (libnix.a).
* Run `test' on `make check'.
2003-06-20 10:53:04 +00:00
Eelco Dolstra 1849aa2a72 * Refactoring: move dump function into archive.cc. 2003-06-20 10:40:25 +00:00
Eelco Dolstra 38e12df631 * `nix --dump' command. 2003-06-18 14:34:43 +00:00