From 1f455fdca60c90710322d99ac529a31d71764a0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Wed, 26 Sep 2012 21:58:48 +0200 Subject: [PATCH] distro: Rename (distro ...) to (distro packages ...). * distro/base.scm, distro/ld-wrapper.scm: Move to `distro/packages'. Adjust LD-WRAPPER-BOOT3 input file name accordingly. * Makefile.am (MODULES): Adjust accordingly. * distro.scm (%distro-module-directory): Change to "/distro/packages". * guix/build-system/gnu.scm (standard-inputs): Change module name to (distro packages base). * tests/packages.scm (test-packages): Likewise. --- Makefile.am | 4 ++-- distro.scm | 2 +- distro/{ => packages}/base.scm | 5 +++-- distro/{ => packages}/ld-wrapper.scm | 4 ++-- guix/build-system/gnu.scm | 4 ++-- tests/packages.scm | 2 +- 6 files changed, 11 insertions(+), 10 deletions(-) rename distro/{ => packages}/base.scm (99%) rename distro/{ => packages}/ld-wrapper.scm (98%) diff --git a/Makefile.am b/Makefile.am index 3de64a4edd6010964ce97037978824218c2ec4bf..88f3d87796bff154841785968463c8c531301965 100644 --- a/Makefile.am +++ b/Makefile.am @@ -35,8 +35,8 @@ MODULES = \ guix/packages.scm \ guix.scm \ distro.scm \ - distro/base.scm \ - distro/ld-wrapper.scm + distro/packages/base.scm \ + distro/packages/ld-wrapper.scm GOBJECTS = $(MODULES:%.scm=%.go) diff --git a/distro.scm b/distro.scm index b21b0e61846bcb9efb96dc0565417a8accc852c2..79e09a3cc6ec1fa74b257d325abc30938364b9dc 100644 --- a/distro.scm +++ b/distro.scm @@ -48,7 +48,7 @@ (define %distro-module-directory ;; Absolute path of the (distro ...) module root. (string-append (dirname (search-path %load-path "distro.scm")) - "/distro")) + "/distro/packages")) (define (package-files) "Return the list of files that implement distro modules." diff --git a/distro/base.scm b/distro/packages/base.scm similarity index 99% rename from distro/base.scm rename to distro/packages/base.scm index bf49d02f20901b2f22b4c37c0d6041676addc96c..67b8b1c6023810af900b470824e2c582bb64a599 100644 --- a/distro/base.scm +++ b/distro/packages/base.scm @@ -16,7 +16,7 @@ ;;; You should have received a copy of the GNU General Public License ;;; along with Guix. If not, see . -(define-module (distro base) +(define-module (distro packages base) #:use-module (distro) #:use-module (guix packages) #:use-module (guix ftp) @@ -1676,7 +1676,8 @@ exec ~a/bin/~a-gcc -B~a/lib -Wl,-dynamic-linker -Wl,~a/lib/~a \"$@\"~%" (build-system trivial-build-system) (inputs `(("binutils" ,binutils-final) ("guile" ,(nixpkgs-derivation* "guile")) - ("wrapper" ,(search-path %load-path "distro/ld-wrapper.scm")))) + ("wrapper" ,(search-path %load-path + "distro/packages/ld-wrapper.scm")))) (arguments `(#:modules ((guix build utils)) #:builder (begin diff --git a/distro/ld-wrapper.scm b/distro/packages/ld-wrapper.scm similarity index 98% rename from distro/ld-wrapper.scm rename to distro/packages/ld-wrapper.scm index 9d3e8008b3e76c5ed827d7fec2d06ecd5f7fbbe6..9b8a09f067607096088c71d7d65f0a276a937207 100644 --- a/distro/ld-wrapper.scm +++ b/distro/packages/ld-wrapper.scm @@ -7,7 +7,7 @@ # Use `load-compiled' because `load' (and `-l') doesn't otherwise load our # .go file (see ). -main="(@ (distro ld-wrapper) ld-wrapper)" +main="(@ (distro packages ld-wrapper) ld-wrapper)" exec @GUILE@ -c "(load-compiled \"$0.go\") (apply $main (cdr (command-line)))" "$@" !# ;;; Guix --- Nix package management from Guile. -*- coding: utf-8 -*- @@ -28,7 +28,7 @@ exec @GUILE@ -c "(load-compiled \"$0.go\") (apply $main (cdr (command-line)))" " ;;; You should have received a copy of the GNU General Public License ;;; along with Guix. If not, see . -(define-module (distro ld-wrapper) +(define-module (distro packages ld-wrapper) #:use-module (srfi srfi-1) #:export (ld-wrapper)) diff --git a/guix/build-system/gnu.scm b/guix/build-system/gnu.scm index 20f5bbacfce56e40f8600431ce2902ea9fc25574..b4a498bee76ccffac668982fe65c415dc63e5a1d 100644 --- a/guix/build-system/gnu.scm +++ b/guix/build-system/gnu.scm @@ -87,8 +87,8 @@ System: GCC, GNU Make, Bash, Coreutils, etc." (z (error "invalid standard input" z))) - ;; Resolve (distro base) lazily to hide circular dependency. - (let* ((distro (resolve-module '(distro base))) + ;; Resolve (distro packages base) lazily to hide circular dependency. + (let* ((distro (resolve-module '(distro packages base))) (inputs (module-ref distro '%final-inputs))) (append inputs (append-map (match-lambda diff --git a/tests/packages.scm b/tests/packages.scm index 48a4a38fea08e017bbe491b2b1342780b5db0dcf..20f586e4494c2e5a89f1d71c931cdc48e1a43b37 100644 --- a/tests/packages.scm +++ b/tests/packages.scm @@ -25,7 +25,7 @@ #:use-module (guix build-system trivial) #:use-module (guix build-system gnu) #:use-module (distro) - #:use-module (distro base) + #:use-module (distro packages base) #:use-module (srfi srfi-26) #:use-module (srfi srfi-64) #:use-module (ice-9 match))