* guix/packages.scm (package-source-derivation): Add `system'
parameter. Pass it to METHOD.
(package-derivation)[expand-input]: Pass SYSTEM to
`package-derivation' and `package-source-derivation'.
* distro/packages/base.scm (package-with-bootstrap-guile)[boot]: Pass
SYSTEM to FETCH.
* guix/packages.scm (package-derivation)[intern]: New procedure. Pass
#t as the `recursive?' argument, instead of #f.
[expand-input]: New procedure, with code formerly in the body.
Support inputs where the input is a procedure returning a file name or
an <origin>.
Use `expand-input' in the body.
* tests/packages.scm ("trivial with system-dependent input"): New test.
* guix/packages.scm (%derivation-cache): Pass an initial size of 100.
(cache): Use `hashq-set!', and use a SYSTEM/DRV pair as the value.
(cached-derivation): Update accordingly.
* guix/build-system/trivial.scm: New file.
* Makefile.am (MODULES): Add it.
* tests/packages.scm ("trivial"): New test.
* guix/packages.scm (package-derivation): Allow SOURCE to be #f.
* guix/packages.scm (transitive-inputs): New procedure.
(package-transitive-inputs): Rewrite in terms of `transitive-inputs'.
(package-transitive-propagated-inputs): New procedure.
* guix/packages.scm (&package-error, &package-input-error): New
condition types.
(package-derivation): Raise a `&package-input-error' when no match is
made.
* guix/packages.scm (package-transitive-inputs): New procedure.
(package-derivation): Use it to compute INPUTS.
* tests/packages.scm (dummy-package): New macro.
("package-transitive-inputs"): New test.
* guix/packages.scm (<package-source>): Rename to...
(<origin>): ... this. Update users.
* distro/base.scm (libsigsegv, gawk, hello): Adjust to renaming; refer
to VERSION to build the URL.
* guix/packages.scm (package-derivation): When ARGS is a procedure, call
(ARGS SYSTEM).
* distro/base.scm (gawk)[arguments]: Turn into a procedure, to disable
tests on Cygwin.
* guix/packages.scm (<package>)[arguments]: Default to '().
* distro/base.scm (libsigsegv, gawk): New packages.
(hello): Use GAWK instead of (nixpkgs-derivation "gawk").
* guix/packages.scm (<location>): New record type.
(location, source-properties->location): New procedures.
(<package>)[location]: New field.
* tests/packages.scm ("GNU Hello"): Test `package-location'.
* Makefile.am (MODULES): Add `guix/packages.scm' and `distro/base.scm'.
(TESTS): Add `tests/packages.scm'.
(EXTRA_DIST): New variable.
* guix/packages.scm, distro/base.scm, tests/packages.scm: New files.
* guix/http.scm (http-fetch): Make `name' an optional argument, to match
the expectations of `package-source-derivation'.