From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id B5818139085 for ; Wed, 1 Feb 2017 22:18:33 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 2623F21C206; Wed, 1 Feb 2017 22:18:33 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id E5B2621C206 for ; Wed, 1 Feb 2017 22:18:32 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id E35BE33BF1B for ; Wed, 1 Feb 2017 22:18:31 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 8BEEE3DAB for ; Wed, 1 Feb 2017 22:18:30 +0000 (UTC) From: "Sergei Trofimovich" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sergei Trofimovich" Message-ID: <1485987496.f7663b92c6722a14a928fde1809e52748cb2e97a.slyfox@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/guix/, sys-apps/guix/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-apps/guix/Manifest sys-apps/guix/files/guix-0.12.0-AR.patch sys-apps/guix/files/guix-0.12.0-no-json-crate.patch sys-apps/guix/files/guix-daemon.initd sys-apps/guix/guix-0.12.0-r1.ebuild sys-apps/guix/metadata.xml X-VCS-Directories: sys-apps/guix/files/ sys-apps/guix/ X-VCS-Committer: slyfox X-VCS-Committer-Name: Sergei Trofimovich X-VCS-Revision: f7663b92c6722a14a928fde1809e52748cb2e97a X-VCS-Branch: master Date: Wed, 1 Feb 2017 22:18:30 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 507a58ed-6b78-4a50-89b1-2f3b7fc1376a X-Archives-Hash: 293c272e40f8611b1f407bae6466391b commit: f7663b92c6722a14a928fde1809e52748cb2e97a Author: Sergei Trofimovich gentoo org> AuthorDate: Wed Feb 1 22:18:04 2017 +0000 Commit: Sergei Trofimovich gentoo org> CommitDate: Wed Feb 1 22:18:16 2017 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f7663b92 sys-apps/guix: new package, the GNU Purely Functional Package Manager Internal data model and command UI is a lot like one of sys-apps/nix. Package description mechanism is a bit different in both surface syntax (guile vs nix expression language) and evaluation method (compiled versus lazy loaded configs) guix (as well as nix) is a source-based package manager with strong support for binary packages. It uses multiple tricks to make package source dependencies robust: - guix installs every package into it's own --prefix=. Example: /gnu/store/6np03bm99hg7gprcwmzpbpaj00cka8p8-icecat-45.5.1-gnu1 - guix builds packages with PATH (and similar) only including explicitly listed depends. This eliminates automagic dependency. - guix tracks full environment where package was built. Once environment changes new package needs to be built. That's how you install firef^Wicecat just for your current user: $ guix package --install icecat Package-Manager: Portage-2.3.3, Repoman-2.3.1 sys-apps/guix/Manifest | 1 + sys-apps/guix/files/guix-0.12.0-AR.patch | 8 ++ .../guix/files/guix-0.12.0-no-json-crate.patch | 38 +++++++++ sys-apps/guix/files/guix-daemon.initd | 16 ++++ sys-apps/guix/guix-0.12.0-r1.ebuild | 92 ++++++++++++++++++++++ sys-apps/guix/metadata.xml | 8 ++ 6 files changed, 163 insertions(+) diff --git a/sys-apps/guix/Manifest b/sys-apps/guix/Manifest new file mode 100644 index 00000000..1cef361 --- /dev/null +++ b/sys-apps/guix/Manifest @@ -0,0 +1 @@ +DIST guix-0.12.0.tar.gz 15823786 SHA256 6201e21186a7098af256d97562662d95353b1047799b9b216e1dd6e7692dfec9 SHA512 d61cb289d3773977400fa3c49869f30a3feb5e0364368017b9b8eaadee814c5c31897be398d6ff142349337334eb51cb6d0354bee27c0365de69ce1a09e858d3 WHIRLPOOL 9515967a05a449f24da49e95340a60fb91cc471fcc532ce6cfaaea82c9161e3a65a1adc4d95e9997f019565243ca385845edc484981adfc5956112092687a0ec diff --git a/sys-apps/guix/files/guix-0.12.0-AR.patch b/sys-apps/guix/files/guix-0.12.0-AR.patch new file mode 100644 index 00000000..c9c91c2 --- /dev/null +++ b/sys-apps/guix/files/guix-0.12.0-AR.patch @@ -0,0 +1,8 @@ +diff --git a/config-daemon.ac b/config-daemon.ac +index 056c939..b04deed 100644 +--- a/config-daemon.ac ++++ b/config-daemon.ac +@@ -7,2 +7,3 @@ dnl C++ environment. This macro must be used unconditionnaly. + AC_PROG_CXX ++AM_PROG_AR + AC_LANG([C++]) diff --git a/sys-apps/guix/files/guix-0.12.0-no-json-crate.patch b/sys-apps/guix/files/guix-0.12.0-no-json-crate.patch new file mode 100644 index 00000000..57b4308 --- /dev/null +++ b/sys-apps/guix/files/guix-0.12.0-no-json-crate.patch @@ -0,0 +1,38 @@ +commit 6023041346c79f7ac4105bba2552a82019fae840 +Author: David Thompson +Date: Fri Dec 30 14:15:35 2016 -0500 + + import: crate: Do not build when guile-json is not available. + + * Makefile.am (MODULES): Add 'guix/import/crate.scm' and + 'guix/scripts/import/crate.scm' only when HAVE_GUILE_JSON. + +diff --git a/Makefile.am b/Makefile.am +index 15939af12..97629f26e 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -122,7 +122,6 @@ MODULES = \ + guix/import/snix.scm \ + guix/import/cabal.scm \ + guix/import/cran.scm \ +- guix/import/crate.scm \ + guix/import/hackage.scm \ + guix/import/elpa.scm \ + guix/scripts.scm \ +@@ -142,7 +141,6 @@ MODULES = \ + guix/scripts/lint.scm \ + guix/scripts/challenge.scm \ + guix/scripts/import/cran.scm \ +- guix/scripts/import/crate.scm \ + guix/scripts/import/gnu.scm \ + guix/scripts/import/nix.scm \ + guix/scripts/import/hackage.scm \ +@@ -162,6 +160,8 @@ if HAVE_GUILE_JSON + MODULES += \ + guix/import/github.scm \ + guix/import/json.scm \ ++ guix/import/crate.scm \ ++ guix/scripts/import/crate.scm \ + guix/import/pypi.scm \ + guix/scripts/import/pypi.scm \ + guix/import/cpan.scm \ diff --git a/sys-apps/guix/files/guix-daemon.initd b/sys-apps/guix/files/guix-daemon.initd new file mode 100644 index 00000000..c4f2579 --- /dev/null +++ b/sys-apps/guix/files/guix-daemon.initd @@ -0,0 +1,16 @@ +#!/sbin/openrc-run +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start --quiet --background --exec /usr/bin/guix-daemon -- --build-users-group=guixbuild + eend ${?} +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop --quiet --exec /usr/bin/guix-daemon + eend ${?} +} diff --git a/sys-apps/guix/guix-0.12.0-r1.ebuild b/sys-apps/guix/guix-0.12.0-r1.ebuild new file mode 100644 index 00000000..104b21d --- /dev/null +++ b/sys-apps/guix/guix-0.12.0-r1.ebuild @@ -0,0 +1,92 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 + +inherit autotools readme.gentoo-r1 user + +DESCRIPTION="GNU package manager (nix sibling)" +HOMEPAGE="https://www.gnu.org/software/guix/" + +SRC_URI="mirror://gnu-alpha/${PN}/${P}.tar.gz" +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +RESTRICT=test # complains about size of config.log and refuses to start tests + +RDEPEND=" + dev-libs/libgcrypt:0= + >=dev-scheme/guile-2 + sys-libs/zlib + app-arch/bzip2 + dev-db/sqlite +" + +DEPEND="${RDEPEND} +" + +QA_PREBUILT="usr/share/guile/site/2.0/gnu/packages/bootstrap/*" + +PATCHES=( + "${FILESDIR}"/${P}-no-json-crate.patch + "${FILESDIR}"/${P}-AR.patch +) + +DISABLE_AUTOFORMATTING=yes +DOC_CONTENTS="Quick start user guide on Gentoo: + +[as root] allow binary substitution to be downloaded (optional) + # guix archive --authorize < /usr/share/guix/hydra.gnu.org.pub +[as root] enable guix-daemon service: + [systemd] # systemctl enable guix-daemon + [openrc] # rc-update add guix-daemon +[as an user] ln -sf /var/guix/profiles/per-user/\$USER/guix-profile \$HOME/.guix-profile +[as an user] install guix packages: + \$ guix package -i hello +[as an user] configure environment: + Somewhere in .bash_profile you might want to set + export GUIX_LOCPATH=\$HOME/.guix-profile/lib/locale + +Next steps: + guix package manager user manual: https://www.gnu.org/software/guix/manual/guix.html +" + +pkg_setup() { + enewgroup guixbuild + for i in {1..10}; do + # we list 'guixbuild' twice to + # both assign a primary group for user + # and add an user to /etc/group + enewuser guixbuilder${i} -1 -1 /var/empty guixbuild,guixbuild + done +} + +src_prepare() { + default + + eautoreconf +} + +src_install() { + # TODO: emacs highlighter + default + + readme.gentoo_create_doc + + # TODO: will need a tweak for prefix + keepdir /gnu/store + fowners root:guixbuild /gnu/store + fperms 1775 /gnu/store + + keepdir /var/guix/profiles/per-user + fperms 1777 /var/guix/profiles/per-user + + newinitd "${FILESDIR}"/guix-daemon.initd guix-daemon +} + +pkg_postinst() { + readme.gentoo_print_elog +} diff --git a/sys-apps/guix/metadata.xml b/sys-apps/guix/metadata.xml new file mode 100644 index 00000000..b787881 --- /dev/null +++ b/sys-apps/guix/metadata.xml @@ -0,0 +1,8 @@ + + + + + haskell@gentoo.org + Gentoo Haskell + +