From f9ec4c69328af0341fab4f5abf508433a288d02f Mon Sep 17 00:00:00 2001 From: Felix Morgner Date: Fri, 23 Feb 2018 14:43:31 +0100 Subject: [PATCH] update to 2.0 --- .SRCINFO | 10 +++------- PKGBUILD | 14 +++++++------- fix_perllibdir.patch | 12 ------------ nix.install | 36 +++++++++++++++++++++--------------- 4 files changed, 31 insertions(+), 41 deletions(-) delete mode 100644 fix_perllibdir.patch diff --git a/.SRCINFO b/.SRCINFO index 13e7aed..e303f97 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,6 +1,6 @@ pkgbase = nix pkgdesc = A purely functional package manager - pkgver = 1.11.16 + pkgver = 2.0 pkgrel = 1 url = https://nixos.org/nix install = nix.install @@ -10,14 +10,10 @@ pkgbase = nix makedepends = bzip2 makedepends = gc makedepends = openssl - depends = perl-www-curl - depends = perl-dbd-sqlite depends = gc depends = libsodium - source = https://nixos.org/releases/nix/nix-1.11.16/nix-1.11.16.tar.xz - source = fix_perllibdir.patch - sha256sums = 0ca5782fc37d62238d13a620a7b4bff6a200bab1bd63003709249a776162357c - sha256sums = 6d5a79602944b560f9b571c8db4efa1b26d4495e6160c5e18c2efbdd2e611c80 + source = https://nixos.org/releases/nix/nix-2.0/nix-2.0.tar.xz + sha256sums = 7024d327314bf92c1d3e6cccd944929828a44b24093954036bfb0115a92f5a14 pkgname = nix diff --git a/PKGBUILD b/PKGBUILD index 3189ef8..3eb7557 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,25 +1,25 @@ -# Maintainer: Vlad M. +# Maintainer: Felix Morgner +# Contributor: Vlad M. # Contributor: Mario Rodas # Contributor: Oozyslug # Contributor: koral pkgname=nix -pkgver=1.11.16 +pkgver=2.0 pkgrel=1 pkgdesc="A purely functional package manager" arch=('i686' 'x86_64') url="https://nixos.org/nix" license=('LGPL') -depends=('perl-www-curl' 'perl-dbd-sqlite' 'gc' 'libsodium') +depends=('gc' 'libsodium') makedepends=('bzip2' 'gc' 'openssl') install=nix.install -source=("https://nixos.org/releases/nix/nix-$pkgver/nix-$pkgver.tar.xz" "fix_perllibdir.patch") -sha256sums=('0ca5782fc37d62238d13a620a7b4bff6a200bab1bd63003709249a776162357c' - '6d5a79602944b560f9b571c8db4efa1b26d4495e6160c5e18c2efbdd2e611c80') +source=("https://nixos.org/releases/nix/nix-$pkgver/nix-$pkgver.tar.xz") +sha256sums=('7024d327314bf92c1d3e6cccd944929828a44b24093954036bfb0115a92f5a14') + prepare() { cd "$pkgname-$pkgver" - patch -Np1 -i "${srcdir}/fix_perllibdir.patch" } build () { diff --git a/fix_perllibdir.patch b/fix_perllibdir.patch deleted file mode 100644 index 2cb718b..0000000 --- a/fix_perllibdir.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -ura a/Makefile.config.in b/Makefile.config.in ---- a/Makefile.config.in 1970-01-01 00:00:01.000000000 +0000 -+++ b/Makefile.config.in 2017-09-03 17:04:53.032445157 +0000 -@@ -26,7 +26,7 @@ - mandir = @mandir@ - perl = @perl@ - perlbindings = @perlbindings@ --perllibdir = @perllibdir@ -+perllibdir = $(shell perl -V:vendorarch|cut -d\' -f2) - pkglibdir = $(libdir)/$(PACKAGE_NAME) - prefix = @prefix@ - storedir = @storedir@ diff --git a/nix.install b/nix.install index e9adc0c..613cee6 100644 --- a/nix.install +++ b/nix.install @@ -49,27 +49,33 @@ restore_store() { chown root.root /nix/store } +init_channels() { + # Initialize default nix channel + echo "Initializing default nix channel" + source /etc/profile.d/nix.sh + nix-channel --update +} + daemon_info() { - if [ ! -d /nix/var/nix/profiles/per-user/root ]; then - echo "To start the nix daemon, execute one of the following:" - echo - echo " systemctl enable nix-daemon.socket # Sets the daemon to start on next boot" - echo " systemctl enable --now nix-daemon.socket # Starts now and on next boot too" - echo - echo "Also, if this is a new install, you need to start a new login shell or otherwise" - echo - echo " source /etc/profile.d/nix.sh" - echo " source /etc/profile.d/nix-daemon.sh" - echo - echo "Once your environment is set-up, you will need to add some channels. You can see how" - echo "to do that here:" - echo " https://nixos.org/nix/manual/#sec-channels" - fi + echo "To start the nix daemon, execute one of the following:" + echo + echo " systemctl enable nix-daemon.socket # Sets the daemon to start on next boot" + echo " systemctl enable --now nix-daemon.socket # Starts now and on next boot too" + echo + echo "Also, if this is a new install, you need to start a new login shell or otherwise" + echo + echo " source /etc/profile.d/nix.sh" + echo " source /etc/profile.d/nix-daemon.sh" + echo + echo "Once your environment is set-up, you will need to add some channels. You can see how" + echo "to do that here:" + echo " https://nixos.org/nix/manual/#sec-channels" } post_install() { create_users create_store + init_channels daemon_info } -- 2.41.0