summaryrefslogtreecommitdiff
path: root/guix/packages.scm
AgeCommit message (Collapse)Author
2014-08-28gnu: Split (gnu packages base), adding (gnu packages commencement).Ludovic Courtès
* gnu/packages/base.scm (gnu-make-boot0, diffutils-boot0, findutils-boot0, %boot0-inputs, nix-system->gnu-triplet, boot-triplet, binutils-boot0, gcc-boot0, perl-boot0, linux-libre-headers-boot0, texinfo-boot0, %boot1-inputs, glibc-final-with-bootstrap-bash, cross-gcc-wrapper, static-bash-for-glibc, glibc-final, gcc-boot0-wrapped, %boot2-inputs, binutils-final, libstdc++, gcc-final, ld-wrapper-boot3, %boot3-inputs, bash-final, %boot4-inputs, guile-final, gnu-make-final, ld-wrapper, coreutils-final, grep-final, %boot5-inputs, %final-inputs, canonical-package, gcc-toolchain, gcc-toolchain-4.8, gcc-toolchain-4.9): Move to... * gnu/packages/commencement.scm: ... here. New file. * gnu-system.am (GNU_SYSTEM_MODULES): Add it. * build-aux/check-final-inputs-self-contained.scm: Adjust accordingly. * gnu/packages/cross-base.scm: Likewise. * gnu/packages/make-bootstrap.scm: Likewise. * guix/build-system/cmake.scm (cmake-build): Likewise. * guix/build-system/gnu.scm (standard-packages, gnu-build, gnu-cross-build): Likewise. * guix/build-system/perl.scm (perl-build): Likewise. * guix/build-system/python.scm (python-build): Likewise. * guix/build-system/trivial.scm (guile-for-build): Likewise. * guix/download.scm (url-fetch): Likewise. * guix/gexp.scm (default-guile): Likewise. * guix/git-download.scm (git-fetch): Likewise. * guix/monads.scm (run-with-store): Likewise. * guix/packages.scm (default-guile): Likewise. * guix/scripts/package.scm (guix-package): Likewise. * guix/scripts/refresh.scm: Likewise. * guix/svn-download.scm (svn-fetch): Likewise. * tests/builders.scm (%bootstrap-inputs, %bootstrap-search-paths): Likewise. * tests/packages.scm ("GNU Make, bootstrap"): Likewise. * tests/guix-package.sh: Likewise. * gnu/services/base.scm: Use 'canonical-package' instead of xxx-final. * gnu/services/xorg.scm: Likewise. * gnu/system/vm.scm: Likewise. * guix/scripts/pull.scm (guix-pull): Likewise.
2014-07-21Add comments about global memoization.Ludovic Courtès
* guix/build-system/gnu.scm (standard-inputs): Add comment about misplaced memoization. * guix/packages.scm (cache): Likewise.
2014-07-20guix: refresh: Add --list-dependent option.Eric Bavier
* guix/packages.scm (package-direct-inputs): New procedure. * gnu/packages.scm (vhash-refq, package-direct-dependents) (package-transitive-dependents, package-covering-dependents): New procedures. * guix/scripts/refresh.scm (%options, show-help, guix-refresh): Add --list-dependent option. * doc/guix.texi (Invoking guix refresh): Document '--list-dependent' option.
2014-07-11packages: Add printer for <origin>.Ludovic Courtès
* guix/packages.scm (print-origin): New procedure. (<origin>): Add it as record type printer.
2014-04-12packages: Correctly handle patching for inputs with no extension.Ludovic Courtès
Reported by Manolis Ragkousis <manolis837@gmail.com>. * guix/packages.scm (patch-and-repack)[numeric-extension?]: Handle FILE-NAME with no extension.
2014-03-10Change default store values from /nix/store to /gnu/store.Ludovic Courtès
* gnu/packages/ld-wrapper.scm (%store-directory): Change the default to /gnu/store. * guix/build/utils.scm (%store-directory): New procedure. (remove-store-references): Use it for the default value of 'store'. * guix/packages.scm (patch-and-repack)[builder]: Change default store to /gnu/store.
2014-02-28packages: Support 'patches' and 'snippets' for sources that are directories.Ludovic Courtès
* guix/packages.scm (patch-and-repack)[numeric-extension?, tarxz-name]: New procedures. [builder]: Adjust to deal with SOURCE when it's a directory. <body>: Use 'tarxz-name'. Always add (guix build utils) to IMPORTED-MODULES.
2014-02-21Add (guix git-download).Ludovic Courtès
* guix/git-download.scm, guix/build/git.scm: New files. * Makefile.am (MODULES): Add them. * guix/packages.scm (<origin>): Fix comment for 'method' field.
2013-12-04derivations: Use more keyword parameters for 'build-expression->derivation'.Ludovic Courtès
* guix/derivations.scm (build-expression->derivation): Turn 'system' and 'inputs' into keyword parameters. Adjust callers accordingly. * gnu/system/linux.scm, gnu/system/vm.scm, guix/build-system/cmake.scm, guix/build-system/gnu.scm, guix/build-system/perl.scm, guix/build-system/python.scm, guix/build-system/trivial.scm, guix/download.scm, guix/packages.scm, guix/profiles.scm, guix/scripts/pull.scm, tests/derivations.scm, tests/guix-build.sh, tests/monads.scm, tests/store.scm, tests/union.scm: Adjust users of 'build-expression->derivation' and 'derivation-expression' accordingly. * doc/guix.texi (Derivations): Adjust 'build-expression->derivation' documentation accordingly. (The Store Monad): Likewise for 'derivation-expression'.
2013-11-20Merge branch 'master' into core-updatesLudovic Courtès
Conflicts: guix/packages.scm
2013-11-18packages: 'package-field-location' returns a relative file name.Ludovic Courtès
* guix/packages.scm (package-field-location): Set %FILE-PORT-NAME-CANONICALIZATION. * tests/packages.scm ("package-field-location, relative file name"): New test.
2013-11-13packages: Suitably cope with indirect store paths as package sources.Ludovic Courtès
* guix/packages.scm (package-source-derivation): Don't let indirect store paths pass through. * tests/packages.scm ("package-source-derivation, indirect store path"): New test.
2013-11-08Merge branch 'master' into core-updatesLudovic Courtès
Conflicts: guix/packages.scm
2013-11-07packages: Add a 'snippet' field to <origin>.Ludovic Courtès
* guix/packages.scm (<origin>): Add 'snippet', 'modules', and 'imported-modules' fields. (patch-and-repack): Make 'inputs' a keyword parameter. Add 'snippet', 'modules', and 'imported-modules' parameters. Accept SOURCE as a raw file name. Insert SNIPPET in BUILDER. Pass IMPORTED-MODULES to 'build-expression->derivation'. (package-source-derivation): Pass the extra arguments to 'patch-and-repack'. * tests/packages.scm ("package-source-derivation, snippet"): New test. * doc/guix.texi (Defining Packages): Mention the 'patches' and 'snippet' fields. (Invoking guix build): Tell that --source has patches and snippets applied. (Software Freedom): Mention packages that contain non-free code.
2013-10-10packages: The 'patch-guile' field of <origin> is now a package.Ludovic Courtès
* guix/packages.scm (default-guile): Return a package instead of a derivation. (package-source-derivation): Adjust accordingly.
2013-10-09packages: Add 'patches' and related fields to <origin>.Ludovic Courtès
See <https://lists.gnu.org/archive/html/guix-devel/2013-09/msg00137.html> for the rationale. * guix/packages.scm (<origin>)[patches, patch-flags, patch-inputs, patch-guile]: New fields. (%standard-patch-inputs, default-guile, patch-and-repack): New procedures. (package-source-derivation): When 'patches' is non-empty, call 'patch-and-repack'. * guix/utils.scm (file-sans-extension): New procedure.
2013-09-25packages: Make the 'output' parameter of 'package-output' optional.Ludovic Courtès
* guix/packages.scm (package-output): Make the 'output' parameter optional.
2013-09-18derivations: 'derivation' and related procedures return a single value.Ludovic Courtès
* guix/derivations.scm (derivation->output-path, derivation->output-paths): New procedures. (derivation-path->output-path): Use 'derivation->output-path'. (derivation-path->output-paths): Use 'derivation->output-paths'. (derivation): Accept 'derivation?' objects as inputs. Return a single value. (build-derivations): New procedure. (compiled-modules): Use 'derivation->output-paths'. (build-expression->derivation)[source-path]: Add case for when the input matches 'derivation?'. [prologue]: Accept 'derivation?' objects in INPUTS. [mod-dir, go-dir]: Use 'derivation->output-path'. * guix/download.scm (url-fetch): Adjust to the single-value return. * guix/packages.scm (package-output): Use 'derivation->output-path'. * guix/scripts/build.scm (guix-build): When the argument is 'derivation-path?', pass it through 'read-derivation'. Use 'derivation-file-name' to print out the .drv file names, and to register them. Use 'derivation->output-path' instead of 'derivation-path->output-path'. * guix/scripts/package.scm (roll-back): Adjust to the single-value return. (guix-package): Use 'derivation->output-path'. * guix/ui.scm (show-what-to-build): Adjust to deal with 'derivation?' objects instead of .drv file names. * gnu/system/grub.scm (grub-configuration-file): Use 'derivation->output-path' instead of 'derivation-path->output-path'. * gnu/system/vm.scm (qemu-image, system-qemu-image): Likewise. * tests/builders.scm, tests/derivations.scm, tests/packages.scm, tests/store.scm, tests/union.scm: Adjust to the new calling convention. * doc/guix.texi (Defining Packages, The Store, Derivations): Adjust accordingly.
2013-08-24packages: Allow file names as package sources.Ludovic Courtès
* guix/packages.scm (package-source-derivation): Add cases for SOURCE as a store path or user file. * tests/packages.scm ("package-source-derivation, file", "package-source-derivation, store path"): New tests.
2013-06-06packages: Make the `propagated-inputs' field thunked.Ludovic Courtès
* guix/packages.scm (<package>): Make `propagated-inputs' thunked.
2013-05-27packages: Raise an error condition a cross builder is needed but unavailable.Ludovic Courtès
* guix/packages.scm (&package-cross-build-system-error): New condition type. (package-cross-derivation): Raise &package-cross-build-system-error when the build system doesn't support cross builds. * guix/ui.scm (call-with-error-handling): Add package-cross-build-system-error? case. * tests/packages.scm ("package-cross-derivation, no cross builder"): New test.
2013-05-25packages: Make `native-inputs' thunked.Ludovic Courtès
* guix/packages.scm (<package>): Make `native-inputs' thunked.
2013-05-25packages: Re-export `%current-target-system'.Ludovic Courtès
* guix/packages.scm: Re-export `%current-target-system'.
2013-05-24packages: Implement `package-cross-derivation'.Ludovic Courtès
* guix/packages.scm (package-transitive-target-inputs, package-transitive-native-inputs): New procedures. (package-derivation): Parametrize `%current-target-system'. (package-cross-derivation): Implement. * guix/utils.scm (%current-target-system): New variable. * tests/packages.scm ("package-cross-derivation"): New test. * doc/guix.texi (Defining Packages): Document `package-cross-derivation'.
2013-05-24packages: Factorize things common to `package-{,cross-}derivation'.Ludovic Courtès
* guix/packages.scm (expand-input): New procedure, moved out of... (package-derivation): ... here. Adjust accordingly. (package-cross-derivation): Add `cross-system' and `system' parameters.
2013-05-12Move record utilities to (guix records).Ludovic Courtès
* guix/utils.scm (define-record-type*): Move to... * guix/records.scm: ... here. New file. * guix/build-system.scm, guix/packages.scm: Use it. * guix/gnu-maintenance.scm: Likewise. (official-gnu-packages)[alist->record]: Remove. * guix/scripts/substitute-binary.scm: Likewise. (alist->record, object->fields): Remove. * tests/utils.scm ("define-record-type*", "define-record-type* with letrec* behavior", "define-record-type* & inherit", "define-record-type* & inherit & letrec* behavior", "define-record-type* & thunked", "define-record-type* & thunked & default", "define-record-type* & thunked & inherited"): Move to... * tests/records.scm: ... here. New file.
2013-04-30Merge branch 'core-updates'Ludovic Courtès
2013-04-27packages: Work around compiler bug in Guile 2.0.5.Ludovic Courtès
* guix/packages.scm (package-field-location): Work around compiler bug in 2.0.5. Reported by Andreas Enge <andreas@enge.fr>.
2013-04-26Merge branch 'master' into core-updatesLudovic Courtès
Conflicts: Makefile.am gnu/packages/autotools.scm gnu/packages/guile.scm gnu/packages/python.scm gnu/packages/shishi.scm guix/gnu-maintenance.scm guix/scripts/build.scm guix/scripts/gc.scm guix/scripts/package.scm guix/scripts/substitute-binary.scm guix/ui.scm nix/nix-daemon/guix-daemon.cc test-env.in tests/nar.scm tests/store.scm
2013-04-25packages: Use `read' and source properties for `package-field-location'.Ludovic Courtès
* guix/packages.scm (package-field-location): Rewrite using `read' and source properties. Change to return #f upon failure. * tests/packages.scm ("package-field-location"): Check for #f upon failure. * build-aux/sync-synopses.scm: Adjust accordingly.
2013-04-22packages: Add `package-field-location'.Ludovic Courtès
* guix/packages.scm (package-field-location): New procedure. * build-aux/sync-synopses.scm: Use it instead of `package-location'. * tests/packages.scm ("package-field-location"): New test.
2013-03-30packages: Add `native-search-paths' field and honor it.Ludovic Courtès
* guix/packages.scm (<search-path-specification>): New record type. (search-path-specification->sexp): New procedure. (<package>)[native-search-paths]: New field. (package-derivation): Accumulate the search paths, and pass them as #:search-paths toe BUILDER. * guix/build-system/gnu.scm (gnu-build): Add #:search-paths. Compute `implicit-search-paths'. Pass #:search-paths in BUILDER. * guix/build-system/perl.scm (perl-build): Add #:search-paths, pass it to BUILDER with the search paths of PERL. * guix/build-system/cmake.scm (cmake-build): Add #:search-paths, pass it to BUILDER. * guix/build-system/trivial.scm (trivial-build): Add #:search-paths, ignore it. * guix/build/gnu-build-system.scm (set-paths): Add #:search-paths. Remove explicit settings of CPATH, LIBRARY_PATH, and PKG_CONFIG_PATH. Instead, walk SEARCH-PATHS and call `set-path-environment-variable' for them. * guix/build/perl-build-system.scm (perl-build): Remove PERL5LIB setting. * tests/packages.scm ("search paths"): New test. * gnu/packages/bootstrap.scm (%bootstrap-guile)[raw]: Add #:search-paths. (%bootstrap-gcc): Add `native-search-paths' field. * gnu/packages/perl.scm (perl): Likewise. * gnu/packages/pkg-config.scm (pkg-config): Likewise. * gnu/packages/glib.scm (intltool): Remove `arguments'. * gnu/packages/avahi.scm (avahi): Remove #:phases.
2013-03-07packages: Remove the default value for `license'.Ludovic Courtès
* guix/packages.scm (<package>): Remove the default value for `license'. * gnu/packages/bootstrap.scm (package-from-tarball, %bootstrap-glibc, %bootstrap-gcc): Initialize `license'. * tests/packages.scm (dummy-package): Likewise.
2013-02-16packages: Add `package-output'.Ludovic Courtès
* guix/packages.scm (package-output): New procedure. * tests/packages.scm ("package-output"): New test.
2013-02-10Re-export `%current-system' from (guix packages).Ludovic Courtès
* guix/packages.scm: Re-export `%current-system'. * gnu/packages/bdw-gc.scm, gnu/packages/gawk.scm, gnu/packages/gperf.scm, gnu/packages/libffi.scm, gnu/packages/libsigsegv.scm, gnu/packages/libunistring.scm, gnu/packages/lout.scm, gnu/packages/m4.scm, gnu/packages/multiprecision.scm, gnu/packages/ncurses.scm, gnu/packages/perl.scm, gnu/packages/pkg-config.scm, gnu/packages/readline.scm, gnu/packages/recutils.scm, gnu/packages/scheme.scm: Remove (guix utils) import.
2013-01-30store: Remove the `fixed?' parameter from `add-to-store'.Ludovic Courtès
* guix/store.scm (add-to-store): Remove the `fixed?' parameter from the public interface. * gnu/packages/bootstrap.scm, guix-download.in, guix/derivations.scm, guix/packages.scm, tests/derivations.scm: Update all callers accordingly.
2013-01-24packages: Mark the `inputs' field of <package> as thunked.Ludovic Courtès
* guix/packages.scm (<package>)[inputs]: Mark as thunked. (package-derivation)[expand-input]: Remove case where the input is a procedure. * tests/packages.scm ("trivial with system-dependent input"): Remove `lambda', and use (%current-system). * gnu/packages/bootstrap.scm (package-from-tarball): Likewise for `inputs'. (%bootstrap-glibc, %bootstrap-gcc): Likewise. * gnu/packages/scheme.scm (mit-scheme): Likewise.
2013-01-23packages: Mark the `arguments' field of <package> as thunked.Ludovic Courtès
* guix/packages.scm (<package>): Mark `arguments' as thunked. (package-derivation): Adjust accordingly. Parameterize %CURRENT-SYSTEM to SYSTEM, so that arguments can refer to it. * guix/build-system/gnu.scm (package-with-explicit-inputs): Expect `package-arguments' to always return a list, and return a list. (package-with-extra-configure-variable): Likewise. (static-package): Likewise. * gnu/packages/base.scm (patch, findutils, gcc-4.7, binutils-boot0, gcc-boot0, glibc-final-with-bootstrap-bash, cross-gcc-wrapper, static-bash-for-glibc, binutils-final, gcc-final): Change `arguments' from a lambda to a list, and use (%current-system) as needed. (nix-system->gnu-triplet, boot-triplet): Have the first argument default to (%current-system). * gnu/packages/bootstrap.scm (glibc-dynamic-linker): Have `system' default to (%current-system). (%bootstrap-gcc): Change `arguments' to a list. * gnu/packages/gawk.scm (gawk): Likewise. * gnu/packages/m4.scm (m4): Likewise. * gnu/packages/make-bootstrap.scm (%glibc-for-bootstrap): Likewise, and expect `package-arguments' to return a list. (%static-inputs, %gcc-static, tarball-package): Likewise. * gnu/packages/ncurses.scm (ncurses): Likewise.
2013-01-22packages: Remove redundant test for inputs-as-procedures.Ludovic Courtès
* guix/packages.scm (package-derivation)[expand-input]: Remove redundant test when the input is a procedure.
2013-01-20packages: Have `package-derivation' return a <derivation> as a second value.Ludovic Courtès
* guix/packages.scm (cache): Change the `drv' argument to `thunk'. Memoize all the return values of THUNK. (cached-derivation): Remove. (cached): New macro. (package-derivation): Use `cached' instead of `(or (cached-derivation) …)'. * doc/guix.texi (Defining Packages): Update accordingly.
2013-01-17packages: Change `base32' to allow non-literal strings.Ludovic Courtès
* guix/packages.scm (base32): Allow arguments that are not literal strings.
2013-01-06Update license headers.Ludovic Courtès
Change all license headers, except guix/build/* and ld-wrapper.scm, with this code: (use-modules (guix build utils) (srfi srfi-1)) (fluid-set! %default-port-encoding "UTF-8") (substitute* (remove (lambda (f) (or (string-contains f ".tar.") (string-contains f ".git/") (string-contains f ".so") (string-suffix? ".o" f) (string-suffix? ".a" f) (string-suffix? ".go" f) (string-suffix? ".pdf" f) (string-suffix? ".png" f) (string-suffix? ".info" f) (equal? (basename f) "guix-daemon") (equal? (basename f) "nix-setuid-helper") (string-contains f "nix-upstream/") (string-contains f "distro/packages/bootstrap/"))) (find-files "." "\\.[a-z]+$")) (("^([[:graph:]]+) This file is part of Guix." _ comment-start) (string-append comment-start " This file is part of GNU Guix.")) (("^([[:graph:]]+) Guix --- Nix package management.*" _ comment-start) (string-append comment-start " GNU Guix --- Functional package management for GNU\n")) (("^([[:graph:]]+) Guix is " _ comment-start) (string-append comment-start " GNU Guix is ")) (("^([[:graph:]]+) along with Guix." _ comment-start) (string-append comment-start " along with GNU Guix.")) (("^([[:graph:]]+) Copyright \\(C\\)" _ comment-start) (string-append comment-start " Copyright ©"))) Change headers using C-style comments manually.
2012-11-25packages: Add missing export.Ludovic Courtès
* guix/packages.scm: Export `package-home-page'.
2012-11-11Move base32 code to (guix base32).Ludovic Courtès
* guix/utils.scm (bytevector-quintet-ref, bytevector-quintet-ref-right, bytevector-quintet-length, bytevector-quintet-fold, bytevector-quintet-fold-right, make-bytevector->base32-string, %nix-base32-chars, %rfc4648-base32-chars, bytevector->base32-string, bytevector->nix-base32-string, bytevector-quintet-set!, bytevector-quintet-set-right!, base32-string-unfold, base32-string-unfold-right, make-base32-string->bytevector, base32-string->bytevector, nix-base32-string->bytevector): Move to... * guix/base32.scm: ... here. New file. * tests/utils.scm (%nix-hash, "bytevector->base32-string", "base32-string->bytevector", "nix-base32-string->bytevector", "sha256 & bytevector->base32-string"): Move to... * tests/base32.scm: ... here. New file * guix-download.in, guix/derivations.scm, guix/packages.scm, guix/snix.scm, tests/builders.scm, tests/derivations.scm: Adjust accordingly. * guix.scm (%public-modules): Add `base32'.
2012-11-04packages: `description' → `synopsis', `long-description' → `description'.Ludovic Courtès
* guix/packages.scm (<package>): Rename `description' to `synopsis', and `long-description' to `description'. * tests/packages.scm, distro/packages/base.scm, distro/packages/databases.scm, distro/packages/guile.scm, distro/packages/typesetting.scm: Update accordingly. * po/Makevars (XGETTEXT_OPTIONS): Update `--keyword' flags accordingly.
2012-10-27guix-build: Gracefully handle `&package-input-error' conditions.Ludovic Courtès
* guix/packages.scm: Export `package-error?' and `package-input-error?'. * guix-build.in (guix-build): Catch `&package-input-error' conditions, print a human-readable message, and exit.
2012-10-25packages: Pass `system' around.Ludovic Courtès
* 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.
2012-10-21packages: Add support for system-dependent inputs.Ludovic Courtès
* 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.
2012-10-08packages: Fix and optimize memoization of `package-derivation'.Ludovic Courtès
* 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.
2012-10-08packages: Micro-optimize `package-derivation'.Ludovic Courtès
* guix/packages.scm (package-derivation): Move `cache' call before the traversal of PACKAGE's inputs.