Hi,
There are some issues:
1. './pre-inst-env guix-build -K util-linux' raises the following
warning:
kdupexe: warning: no binary for interpreter `@PERL@' found in $PATH
(Yep, I've already tried to add 'perl' as input.)
2. I'm not sure that this formatting
(uri (string-append "mirror://kernel.org/linux/utils/"
name "/v" version "/"
name "-" version ".2" ".tar.xz"))
is valid for the following mirrors:
(kernel.org
"http://www.all.kernel.org/pub/"
"http://ramses.wh2.tu-dresden.de/pub/mirrors/kernel.org/"
"http://linux-kernel.uio.no/pub/"
"http://kernel.osuosl.org/pub/"
"ftp://ftp.funet.fi/pub/mirrors/ftp.kernel.org/pub/")
As far as I can tell, it only works for kernel.org. How to check this?
3. 'util-linux' uses a lot of licenses. According to
'README.licensing', it uses GPLv3+, GPLv2+, GPLv2, LGPLv2+, BSD with
advertising, and Public Domain. GPLv2+ is the default license for code
without an explicitly defined license.
I've found a file that uses the Expat license
(i.e. 'util-linux-2.21.2/config/install-sh') and some files with
suspicious licenses.
Examples:
'util-linux-2.21.2/disk-utils/mkfs.bfs.8':
.\" Copyright 1999 Andries E. Brouwer ([email protected])
.\" May be freely distributed.
What does "free" mean in this context?
'util-linux-2.21.2/disk-utils/mkfs.minix.c':
* (C) 1991 Linus Torvalds. This file may be redistributed as per
* the Linux copyright.
And what does the above mean?
These examples show that we can't rely on 'README.licensing'. I guess
that we can use regexps to match against the licenses that are listed
in 'README.licensing' and check the rest manually.
What would you use?
4. It's necessary to do the following to force Guix to rebuild a
package:
nix-store --delete /nix/store/*-util-linux-2.21.tar.xz
nix-store --delete /nix/store/*-util-linux-2.21
./pre-inst-env guix-build -K util-linux
Is this a bug?
Nikita
From aa8bd9692fe769ef330b8b6fc3675c5390ccb017 Mon Sep 17 00:00:00 2001
From: Nikita Karetnikov <[email protected]>
Date: Sun, 2 Dec 2012 04:22:33 +0000
Subject: [PATCH] distro: Add util-linux.
* distro/packages/util-linux.scm: New file.
* Makefile.am (MODULES): Add it.
---
Makefile.am | 1 +
distro/packages/util-linux.scm | 52 ++++++++++++++++++++++++++++++++++++++++
2 files changed, 53 insertions(+), 0 deletions(-)
create mode 100644 distro/packages/util-linux.scm
diff --git a/Makefile.am b/Makefile.am
index 8bb3b55..4ecd645 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -82,6 +82,7 @@ MODULES = \
distro/packages/system.scm \
distro/packages/texinfo.scm \
distro/packages/time.scm \
+ distro/packages/util-linux.scm \
distro/packages/wget.scm \
distro/packages/which.scm \
distro/packages/zile.scm
diff --git a/distro/packages/util-linux.scm b/distro/packages/util-linux.scm
new file mode 100644
index 0000000..ad6b03b
--- /dev/null
+++ b/distro/packages/util-linux.scm
@@ -0,0 +1,52 @@
+;;; Guix --- Nix package management from Guile. -*- coding: utf-8 -*-
+;;; Copyright (C) 2012 Nikita Karetnikov <[email protected]>
+;;;
+;;; This file is part of Guix.
+;;;
+;;; Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (distro packages util-linux)
+ #:use-module (distro packages compression)
+ #:use-module (distro packages ncurses)
+ #:use-module (guix packages)
+ #:use-module (guix download)
+ #:use-module (guix build-system gnu))
+
+(define-public util-linux
+ (package
+ (name "util-linux")
+ (version "2.21")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "mirror://kernel.org/linux/utils/"
+ name "/v" version "/"
+ name "-" version ".2" ".tar.xz"))
+ (sha256
+ (base32
+ "1rpgghf7n0zx0cdy8hibr41wvkm2qp1yvd8ab1rxr193l1jmgcir"))))
+ (build-system gnu-build-system)
+ (arguments `(#:configure-flags '("--disable-use-tty-group")))
+ (inputs `(("zlib" ,zlib)
+ ("ncurses" ,ncurses)))
+ (home-page "https://www.kernel.org/pub/linux/utils/util-linux/")
+ (synopsis
+ "util-linux is a random collection of utilities for the Linux kernel")
+ (description
+ "util-linux is a random collection of utilities for the Linux kernel.")
+ ;; Note that util-linux doesn't use the same license for all the
+ ;; code. GPLv2+ is the default license for a code without an
+ ;; explicitly defined license.
+ (license '("GPLv3+" "GPLv2+" "GPLv2" "LGPLv2+"
+ "BSD-original" "Expat" "Public Domain"))))
\ No newline at end of file
--
1.7.5.4