Commit Graph

174 Commits (538cc2e0165a32d3c5de9022f522f37880b60f5d)

Author SHA1 Message Date
Ludovic Courtès 538cc2e016 Remove now unneeded (guix build gnome) module.
* guix/build/gnome.scm: Remove.
* Makefile.am (MODULES): Update accordingly.
2014-05-07 14:32:36 +02:00
Ludovic Courtès 26a728eb09 linux-initrd: Delete files from the initrd ramfs when switching roots.
* guix/build/linux-initrd.scm (switch-root): Delete file from the old
  root.  Chdir to / after 'chroot' call.  Re-open file descriptors 0, 1,
  and 2.
  (boot-system): Move 'loading' message after the 'switch-root' call.
* gnu/system.scm (operating-system-boot-script): Add loop that closes
  file descriptor before calling 'execl'.
2014-05-06 18:18:22 +02:00
Ludovic Courtès 1d4628329d linux-initrd: Improve root file system switching.
* guix/build/linux-initrd.scm (move-essential-file-systems,
  switch-root): New procedures.
  (MS_MOVE): New variable.
  (boot-system): Remove 'mount-essential-file-systems' call for ROOT.
  Use 'switch-root' instead of chdir + chroot.
2014-05-04 22:24:47 +02:00
Ludovic Courtès 3c05b4bc25 linux-initrd: Check the root and other early file systems.
* gnu/system.scm (operating-system-derivation)[boot-file-systems]: Keep "/".
* gnu/system/linux-initrd.scm (file-system->spec): Keep the 'check?'
  flag.
  (qemu-initrd)[helper-packages]: New variable.  Pass it as #:to-copy.
  <gexp>: Add 'set-path-environment-variable' call.  Remove #:unionfs
  argument for 'boot-system'.
* gnu/system/vm.scm (%linux-vm-file-systems): Add 'check?' field/
  (virtualized-operating-system): Likewise for the "9p" file system.
* guix/build/linux-initrd.scm (mount-root-file-system): Change #:unionfs
  default.  Call 'check-file-system' before mounting ROOT, when
  VOLATILE-ROOT? is false.
  (check-file-system): New procedure.
  (mount-file-system): Honor 'check?' element in list; add
  'check-file-system' call.
  (boot-system): Remove #:root-fs-type and #:unionfs parameters.
  [root-mount-point?, root-fs-type]: New variables.
  Call 'mount-file-system' on all MOUNTS but "/".
2014-05-04 00:30:39 +02:00
Ludovic Courtès ad896f23a5 activation: Fix deletion of setuid programs.
* guix/build/activation.scm (activate-setuid-programs): When
  %SETUID-DIRECTORY exists, pass the right file names to 'delete-file'.
2014-05-04 00:18:46 +02:00
Ludovic Courtès 03ddfaf5fb vm: Make root file system type a parameter, and default to ext4.
* gnu/system/vm.scm (qemu-image): Add #:file-system-type parameter.
  Pass it to 'initialize-hard-disk'.
* guix/build/linux-initrd.scm (mount-root-file-system): Always honor
  TYPE.
  (boot-system): Change #:root-fs-type to default to "ext4".  Update
  docstring.
* guix/build/vm.scm (initialize-hard-disk): Remove #:mkfs parameter; add
  #:file-system-type.  Adjust 'mkfs' invocation and 'mount' call to
  honor #:file-system-type.
2014-05-03 12:16:23 +02:00
Ludovic Courtès 83bcd0b895 system: Add first-class file system declarations.
* gnu/system.scm (<operating-system>)[initrd]: Default to
  'qemu-initrd'.
  (<file-system>): New record type.
  (operating-system-root-file-system): New procedure.
  (operating-system-derivation): Take the device name for GRUB from
  'operating-system-root-file-system'.  Pass the
  'operating-system-initrd' procedure the list of boot file systems.
* gnu/system/linux-initrd.scm (file-system->spec): New procedure.
  (qemu-initrd): Add 'file-systems' parameter, and remove #:mounts
  parameter.
  [file-system-type-predicate]: New procedure.
  [linux-modules]: Use it.
  Adjust #:mounts argument in 'boot-system' call.
  (gnu-system-initrd): Remove.
* gnu/system/vm.scm (%linux-vm-file-systems): New variable.
  (expression->derivation-in-linux-vm): Adjust call to 'qemu-initrd'.
  (virtualized-operating-system): New procedure.
  (system-qemu-image/shared-store-script)[initrd]: Remove.  Use
  'virtualized-operating-system'.  Get the 'initrd' file from OS-DRV.
* guix/build/linux-initrd.scm (mount-qemu-smb-share, mount-qemu-9p):
  Remove.
  (MS_RDONLY, MS_BIND): New global variables.
  (bind-mount): Remove local 'MS_BIND' definition.
  (mount-root-file-system): New procedure, with code formerly in
  'boot-system'.
  (mount-file-system): New procedure.
  (boot-system): Add #:root-fs-type parameter.  Remove 'MS_RDONLY' local
  variable.  Use 'mount-root-file-system' and 'mount-file-system'.
* doc/guix.texi (Using the Configuration System): Add 'file-system'
  declaration.
2014-05-03 00:46:51 +02:00
Ludovic Courtès 09e028f45f system: Add support for setuid binaries.
* gnu/system.scm (<operating-system>)[pam-services, setuid-programs]:
  New fields.
  (etc-directory)[bashrc]: Prepend /run/setuid-programs to $PATH.
  (operating-system-etc-directory): Honor
  'operating-system-pam-services'.
  (%setuid-programs): New variable.
  (operating-system-boot-script): Add (guix build utils) to the set of
  imported modules.  Call 'activate-setuid-programs' in boot script.
* gnu/system/linux.scm (base-pam-services): New procedure.
* guix/build/activation.scm (%setuid-directory): New variable.
  (activate-setuid-programs): New procedure.
* build-aux/hydra/demo-os.scm: Add 'pam-services' field.
2014-04-30 23:16:23 +02:00
Ludovic Courtès d8a7a5bfd5 linux-initrd: Allow setuid binaries from the unionfs to run.
* guix/build/linux-initrd.scm (boot-system): Pass the 'suid' option to
  UNIONFS.
2014-04-30 23:16:23 +02:00
Ludovic Courtès 4dfe6c58ee system: Add (guix build activation).
* gnu/services/dmd.scm (dmd-configuration-file): Remove 'etc'
  parameter.  Move /etc activation code to...
* guix/build/activation.scm: ... here; new file.
* gnu/system.scm (operating-system-boot-script): Augment script: add
  (guix build activation) to the load path; call 'activate-etc'.
* Makefile.am (MODULES): Add guix/build/activation.scm.
2014-04-30 23:16:22 +02:00
Andreas Enge 06ed59825e guix: cmake: Add input and package libraries to the rpath, and adapt package
definitions accordingly.

* guix/build/cmake-build-system.scm (configure): Add flags.
* gnu/packages/maths.scm (lapack): Drop special code.
* gnu/packages/ssh.scm (libssh): Drop special code.
* gnu/packages/slim.scm (slim): Drop special code and enable shared library.

Co-authored-by: Eric Bavier <bavier@member.fsf.org>
2014-04-27 11:35:26 +02:00
Ludovic Courtès 395bea2a53 download: Improve progress report output.
* guix/build/download.scm (url-fetch): Make current-output-port
  unbuffered.
2014-04-16 12:25:52 +02:00
Ludovic Courtès 1c96c1bbab linux-initrd: Mount / as a unionfs when asking for a volatile root.
* guix/build/linux-initrd.scm (make-essential-device-nodes): Make
  /dev/fuse.
  (boot-system): Add #:unionfs parameter.  Invoke UNIONFS instead of
  copying files over when VOLATILE-ROOT? is true.
* gnu/system/linux-initrd.scm (expression->initrd): Add #:inputs
  parameter.
  [files-to-copy]: New procedure.
  [builder]: Add 'to-copy' parameter; honor it.
  (qemu-initrd)[linux-modules]: Add 'fuse.ko' when VOLATILE-ROOT?.
  Pass UNIONFS-FUSE/STATIC as #:inputs; change builder to pass #:unionfs
  to 'boot-system'.
2014-04-14 23:59:08 +02:00
Ludovic Courtès 55651ff207 vm: Move image creation to (guix build vm); split into several procedures.
* guix/build/vm.scm (read-reference-graph, initialize-partition-table,
  install-grub, populate-store, evaluate-populate-directive,
  reset-timestamps, initialize-hard-disk): New procedures.
* gnu/system/vm.scm (qemu-image): Change 'builder' to a call to
  'initialize-hard-disk'.
2014-04-11 19:08:25 +02:00
Ludovic Courtès e1a87b904a vm: Add (guix build vm) module.
* guix/build/vm.scm: New file.
* Makefile.am (MODULES): Add it.
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Use it.
2014-04-11 19:08:24 +02:00
Ludovic Courtès c865a878a0 gnu: linux-initrd: Mount /dev/pts at boot time.
* guix/build/linux-initrd.scm (make-essential-device-nodes): Remove
  'mount' call for /dev/pts.
  (boot-system): Add it here, after 'chroot' call.
2014-04-09 19:10:07 +02:00
Ludovic Courtès 289773c1d8 gnu: linux-initrd: Better populate /dev.
* guix/build/linux-initrd.scm (make-essential-device-nodes): Make
  /dev/{ptmx,tty} world-writable.  Build additional character devices.
2014-04-09 17:50:37 +02:00
Mark H Weaver 6a0b30f36c union: Ensure that the output is always a directory.
Fixes the creation of single-package profiles, reported by Ludovic Courtès.

* guix/build/union.scm (union-build): Add new internal procedure
  'union-of-directories' that always creates a directory, containing the code
  previously used only to merge multiple directories.  Call it from the
  multiple-directory case in 'union' and from the top-level 'union-build'.
2014-04-03 18:35:16 -04:00
Mark H Weaver 1212999868 union: Rewrite to be faster; handle symlink/directory conflicts.
* guix/build/union.scm: Rewrite; only 'file=?' remains unchanged.  Remove
  'tree-union' and 'delete-duplicate-leaves' exports.  Merge inputs in a
  breadth-first fashion.  Follow symlinks for purposes of making decisions
  about the merge.

* tests/union.scm: Remove tests of 'tree-union' and 'delete-duplicate-leaves'.
2014-04-02 15:31:46 -04:00
Sree Harsha Totakura b3acf3656e Add (guix svn-download).
* guix/svn-download.scm, guix/build/svn.scm: New files.
* Makefile.am (MODULES): Add them.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2014-03-27 00:21:44 +01:00
Ludovic Courtès 4979ee04f0 Merge branch 'core-updates' 2014-03-26 16:31:57 +01:00
Ludovic Courtès 212ece42b0 download: Don't use 'http-get*' on Guile 2.0.10+.
* guix/build/download.scm (http-fetch)[post-2.0.7?]: Use
  'string->number' and numeric comparison.  This fixes version
  comparison with "2.0.10" and subsequent 2.0 releases.
2014-03-25 18:54:52 +01:00
Ludovic Courtès 8be3b8a39b Change default store values from /nix/store to /gnu/store.
* 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-03-10 23:54:27 +01:00
Ludovic Courtès e06f7865e2 Merge branch 'master' into core-updates 2014-03-10 23:54:17 +01:00
Ludovic Courtès c9c88118a1 gnu: linux-initrd: Make the pseudo-tty device nodes.
* guix/build/linux-initrd.scm (make-essential-device-nodes): Create
  /dev/ptmx and /dev/pts.
* gnu/system/vm.scm (qemu-image): Umount /fs/dev/pts before /fs.
2014-03-10 23:43:31 +01:00
Ludovic Courtès 17919a5801 build-system/gnu: Allow the source to be a directory.
* guix/build/gnu-build-system.scm (unpack): Check if SOURCE is a
  directory, and copy it locally if it is.
* gnu/packages/libwebsockets.scm (libwebsockets)[arguments]: Remove
  'unpack' phase.
2014-02-22 00:34:49 +01:00
Ludovic Courtès b2bfa32d25 Merge branch 'master' into core-updates
Conflicts:
	gnu-system.am
2014-02-22 00:27:57 +01:00
Ludovic Courtès 9b5b5c1740 Add (guix git-download).
* guix/git-download.scm, guix/build/git.scm: New files.
* Makefile.am (MODULES): Add them.
* guix/packages.scm (<origin>): Fix comment for 'method' field.
2014-02-21 23:49:53 +01:00
John Darrington c2e6516721 build-system/gnu: Set the docdir to "share/doc"
* guix/build/gnu-build-system.scm (configure):
  Change docdir directory from "doc" to "share/doc".

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2014-02-10 22:22:53 +01:00
Ludovic Courtès 6ede17ca69 union: Do not compare directories upon collision.
* guix/build/union.scm (file=?): Return #f if FILE1 and FILE2 are not
  regular files.  Fixes a bug whereby collisions among directories would
  lead to the invocation of 'file=?' and thus 'call-with-input-file' on
  directories.  Reported by Mark H. Weaver <mhw@netris.org>.
2014-02-10 00:05:39 +01:00
Ludovic Courtès 2de227af4b download: Provide a 'User-Agent' field in HTTP requests.
Fixes <http://bugs.gnu.org/16703>.
Reported by Raimon Grau <raimonster@gmail.com>.

* guix/build/download.scm (http-fetch)[headers]: New variable.
  Pass it as #:headers or #:extra-headers to 'http-get' and
  'http-get*'.
2014-02-10 00:03:34 +01:00
Ludovic Courtès 26fc862a61 gnu: linux-initrd: When booting, chdir to the new root before calling 'chroot'.
* guix/build/linux-initrd.scm (boot-system): Add 'chdir' call right
  before 'chroot'.
2014-02-09 23:28:18 +01:00
Ludovic Courtès 1c2215108b gnu: linux-initrd: Build /dev/input devices.
* guix/build/linux-initrd.scm (make-essential-device-nodes): Make
  dev/input devices.
2014-02-01 02:22:23 +01:00
Ludovic Courtès c04c6ff64c gnu: linux-initrd: Make /dev/{mem,kmem}.
* guix/build/linux-initrd.scm (make-essential-device-nodes): Make
  dev/{mem,kmem}.
2014-02-01 01:07:14 +01:00
Ludovic Courtès 44ddf33ed5 gnu: linux-initrd: Allow the root file system to be volatile.
* gnu/system/linux-initrd.scm (qemu-initrd): Add 'volatile-root?'
  parameter.
* guix/build/linux-initrd.scm (boot-system): Likewise.  Honor it.
2014-01-31 14:26:30 +01:00
Ludovic Courtès 4919d68432 gnu: linux-initrd: Recognize 9p file systems.
* gnu/system/linux-initrd.scm (qemu-initrd)[virtio-9p-modules]: New
  variable.
  [linux-modules]: Append VIRTIO-9P-MODULES when a 9p file system is in
  MOUNTS.
* guix/build/linux-initrd.scm (mount-qemu-9p): New procedure.
  (boot-system): Recognize '9p' in MOUNTS, and use 'mount-qemu-9p'.
2014-01-31 12:52:13 +01:00
Ludovic Courtès fc4bc4b6de gnu: linux-initrd: Properly distinguish between /dev/sda* and /dev/vda*.
* guix/build/linux-initrd.scm (make-essential-device-nodes): Rename
  devices with major = 8 to /dev/sda*.  Make /dev/vda* devices.
* gnu/system/vm.scm (qemu-image): Change '/dev/vda' to '/dev/sda'.
* gnu/system.scm (operating-system-derivation): Likewise.
2014-01-31 01:43:16 +01:00
Ludovic Courtès 83b9e6a185 gnu: linux-initrd: Start a REPL when the root could not be mounted.
* guix/build/linux-initrd.scm (boot-system): Catch errors when mounting
  ROOT and call 'start-repl' upon error.
2014-01-31 01:40:02 +01:00
Ludovic Courtès d425471182 gnu: linux-initrd: Factorize boot code.
* guix/build/linux-initrd.scm (boot-system): New procedure.
* gnu/system/linux-initrd.scm (qemu-initrd): Add keyword parameters
  'guile-modules-in-chroot?' and 'mounts'.  Change builder to simply
  call 'boot-system'.
  (gnu-system-initrd): Change to a simple call to 'qemu-initrd'.
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Call
  'qemu-initrd' with #:guile-modules-in-chroot?.
2014-01-29 21:57:56 +01:00
Ludovic Courtès 49a8b80da6 Revert "build-system/gnu: Pass --localstatedir=/var --sharedstatedir=/com."
This reverts commit 65529e49ff.
2014-01-28 08:57:37 +01:00
Ludovic Courtès 65529e49ff build-system/gnu: Pass --localstatedir=/var --sharedstatedir=/com.
Suggested by John Darrington <john@darrington.wattle.id.au>
and Mark H Weaver <mhw@netris.org>.

* guix/build/gnu-build-system.scm (configure): Pass --localstatedir=/var
  --sharedstatedir=/com.
* gnu/packages/admin.scm (dmd): Remove 'arguments' field.
* gnu/packages/avahi.scm (avahi): Remove --localstatedir flag.
* gnu/packages/glib.scm (dbus): Likewise.
* gnu/packages/package-management.scm (guix): Likewise.
* gnu/packages/pulseaudio.scm (pulseaudio): Likewise.
2014-01-27 23:45:59 +01:00
Ludovic Courtès 200a97e64f Merge branch 'master' into core-updates 2014-01-25 17:07:21 +01:00
Ludovic Courtès b97c95eb3c linux-initrd: Make /dev/{null,zero} world-writable.
Reported by zerwas on #guix.

* guix/build/linux-initrd.scm (make-essential-device-nodes): Make
  /dev/null and /dev/zero world-writable.
2014-01-18 22:32:50 +01:00
John Darrington db6190899e gnu: gnu-build-system: Add CC_FOR_BUILD to configure flags.
* guix/build/gnu-build-system.scm: Add new configure flag: CC_FOR_BUILD=gcc

* gnu/packages/gnupg.scm, gnu/packages/guile.scm, gnu/packages/make-bootstrap.scm:
  remove CC_FOR_BUILD from these package descriptions.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2013-12-17 21:28:07 +01:00
Ludovic Courtès 3dbeecd2ff pull: Move build code to (guix build pull).
* guix/build/pull.scm: New file.
* Makefile.am (MODULES): Add it.
* guix/scripts/pull.scm (unpack): Use it.
2013-12-16 23:26:48 +01:00
Cyril Roelandt af949e8ee7 gnu: gtk+: enable introspection.
* gnu/packages/gtk.scm (atk, gdk-pixbuf, gtk+, pango): enable introspection
* guix/build/gnome.scm: New file.
2013-12-15 23:39:43 +01:00
Ludovic Courtès 977f03ffd3 build-system/cmake: Build out of source tree by default.
* guix/build-system/cmake.scm (cmake-build): Change 'out-of-source?' to
  default to #t.
* guix/build/cmake-build-system.scm (configure): Add 'out-of-source?'
  keyword parameter and honor it.
2013-11-28 00:15:07 +01:00
Ludovic Courtès ff8061b591 Merge branch 'master' into core-updates 2013-11-01 12:59:31 +01:00
Ludovic Courtès cdbca518ca union: Do not warn when identical files collide.
* guix/build/union.scm (file=?): New procedure.
  (union-build)[resolve-collision]: Do not warn when identical files
  collide.
2013-10-31 23:38:58 +01:00
Ludovic Courtès c065c443a0 union: Make the log port a parameter.
* guix/build/union.scm (union-build): Add 'log-port' keyword parameter;
  use it.
2013-10-30 22:09:32 +01:00