diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /sys-apps/nix/files |
reinit the tree, so we can have metadata
Diffstat (limited to 'sys-apps/nix/files')
-rw-r--r-- | sys-apps/nix/files/60nix-remote-daemon | 1 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-1.11.12-etc-fixes.patch | 24 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-1.11.14-etc-fixes.patch | 8 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-1.11.14-glibc-2.26.patch | 16 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-1.11.6-per-user.patch | 11 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-1.11.6-respect-CXXFLAGS.patch | 9 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-1.11.6-respect-LDFLAGS.patch | 36 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-1.11.6-systemd.patch | 10 | ||||
-rw-r--r-- | sys-apps/nix/files/nix-daemon.initd | 15 |
9 files changed, 130 insertions, 0 deletions
diff --git a/sys-apps/nix/files/60nix-remote-daemon b/sys-apps/nix/files/60nix-remote-daemon new file mode 100644 index 000000000000..626058a94d15 --- /dev/null +++ b/sys-apps/nix/files/60nix-remote-daemon @@ -0,0 +1 @@ +NIX_REMOTE="daemon" diff --git a/sys-apps/nix/files/nix-1.11.12-etc-fixes.patch b/sys-apps/nix/files/nix-1.11.12-etc-fixes.patch new file mode 100644 index 000000000000..1973133e22bd --- /dev/null +++ b/sys-apps/nix/files/nix-1.11.12-etc-fixes.patch @@ -0,0 +1,24 @@ +GNU coreutils has '-c' option for formatted output, not -f. +Don't spam stderr when directory gets created. +diff --git a/scripts/nix-profile-daemon.sh.in b/scripts/nix-profile-daemon.sh.in +index 7f46cc6..386f607 100644 +--- a/scripts/nix-profile-daemon.sh.in ++++ b/scripts/nix-profile-daemon.sh.in +@@ -15,3 +15,3 @@ export NIX_PROFILES="@localstatedir@/nix/profiles/default $HOME/.nix-profile" + mkdir -m 0755 -p $NIX_USER_PROFILE_DIR +-if test "$(stat -f '%u' $NIX_USER_PROFILE_DIR)" != "$(id -u)"; then ++if test "$(stat -c '%u' $NIX_USER_PROFILE_DIR)" != "$(id -u)"; then + echo "WARNING: bad ownership on $NIX_USER_PROFILE_DIR" >&2 +@@ -37,3 +37,3 @@ if test -w $HOME; then + mkdir -m 0755 -p $NIX_USER_GCROOTS_DIR +- if test "$(stat -f '%u' $NIX_USER_GCROOTS_DIR)" != "$(id -u)"; then ++ if test "$(stat -c '%u' $NIX_USER_GCROOTS_DIR)" != "$(id -u)"; then + echo "WARNING: bad ownership on $NIX_USER_GCROOTS_DIR" >&2 +diff --git a/scripts/nix-profile.sh.in b/scripts/nix-profile.sh.in +index 4f09b55..e93ef42 100644 +--- a/scripts/nix-profile.sh.in ++++ b/scripts/nix-profile.sh.in +@@ -5,3 +5,2 @@ if [ -n "$HOME" ]; then + if ! [ -L "$NIX_LINK" ]; then +- echo "creating $NIX_LINK" >&2 + _NIX_DEF_LINK=@localstatedir@/nix/profiles/per-user/$USER/profile diff --git a/sys-apps/nix/files/nix-1.11.14-etc-fixes.patch b/sys-apps/nix/files/nix-1.11.14-etc-fixes.patch new file mode 100644 index 000000000000..07962838a224 --- /dev/null +++ b/sys-apps/nix/files/nix-1.11.14-etc-fixes.patch @@ -0,0 +1,8 @@ +diff --git a/scripts/nix-profile.sh.in b/scripts/nix-profile.sh.in +index 4f09b55..e93ef42 100644 +--- a/scripts/nix-profile.sh.in ++++ b/scripts/nix-profile.sh.in +@@ -5,3 +5,2 @@ if [ -n "$HOME" ]; then + if ! [ -L "$NIX_LINK" ]; then +- echo "creating $NIX_LINK" >&2 + _NIX_DEF_LINK=@localstatedir@/nix/profiles/per-user/$USER/profile diff --git a/sys-apps/nix/files/nix-1.11.14-glibc-2.26.patch b/sys-apps/nix/files/nix-1.11.14-glibc-2.26.patch new file mode 100644 index 000000000000..44c995e3239e --- /dev/null +++ b/sys-apps/nix/files/nix-1.11.14-glibc-2.26.patch @@ -0,0 +1,16 @@ +'context' is no more after: +https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=251287734e89a52da3db682a8241eb6bccc050c9 + +'ucontext_t' is the new name. +diff --git a/src/libmain/stack.cc b/src/libmain/stack.cc +index 41b617d..695aaad 100644 +--- a/src/libmain/stack.cc ++++ b/src/libmain/stack.cc +@@ -22,5 +22,5 @@ static void sigsegvHandler(int signo, siginfo_t * info, void * ctx) + #if defined(__x86_64__) && defined(REG_RSP) +- sp = (char *) ((ucontext *) ctx)->uc_mcontext.gregs[REG_RSP]; ++ sp = (char *) ((ucontext_t *) ctx)->uc_mcontext.gregs[REG_RSP]; + #elif defined(REG_ESP) +- sp = (char *) ((ucontext *) ctx)->uc_mcontext.gregs[REG_ESP]; ++ sp = (char *) ((ucontext_t *) ctx)->uc_mcontext.gregs[REG_ESP]; + #else diff --git a/sys-apps/nix/files/nix-1.11.6-per-user.patch b/sys-apps/nix/files/nix-1.11.6-per-user.patch new file mode 100644 index 000000000000..9cea685c59a4 --- /dev/null +++ b/sys-apps/nix/files/nix-1.11.6-per-user.patch @@ -0,0 +1,11 @@ +By default created symlink poins to a directory not accessible by user. +Make a symlink the same way NixOS does symlinking. +diff --git a/scripts/nix-profile.sh.in b/scripts/nix-profile.sh.in +index 672d1f0..e3b0978 100644 +--- a/scripts/nix-profile.sh.in ++++ b/scripts/nix-profile.sh.in +@@ -6,3 +6,3 @@ if [ -n "$HOME" ]; then + echo "creating $NIX_LINK" >&2 +- _NIX_DEF_LINK=@localstatedir@/nix/profiles/default ++ _NIX_DEF_LINK=@localstatedir@/nix/profiles/per-user/$USER/profile + @coreutils@/ln -s "$_NIX_DEF_LINK" "$NIX_LINK" diff --git a/sys-apps/nix/files/nix-1.11.6-respect-CXXFLAGS.patch b/sys-apps/nix/files/nix-1.11.6-respect-CXXFLAGS.patch new file mode 100644 index 000000000000..091fdcacba76 --- /dev/null +++ b/sys-apps/nix/files/nix-1.11.6-respect-CXXFLAGS.patch @@ -0,0 +1,9 @@ +diff --git a/configure.ac b/configure.ac +index 3a24053..1b99702 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -57,4 +57,2 @@ fi + +-CFLAGS= +-CXXFLAGS= + AC_PROG_CC diff --git a/sys-apps/nix/files/nix-1.11.6-respect-LDFLAGS.patch b/sys-apps/nix/files/nix-1.11.6-respect-LDFLAGS.patch new file mode 100644 index 000000000000..12c094eb6180 --- /dev/null +++ b/sys-apps/nix/files/nix-1.11.6-respect-LDFLAGS.patch @@ -0,0 +1,36 @@ +diff --git a/Makefile.config.in b/Makefile.config.in +index f0de4da..c82fbfd 100644 +--- a/Makefile.config.in ++++ b/Makefile.config.in +@@ -5,2 +5,3 @@ CXX = @CXX@ + CXXFLAGS = @CXXFLAGS@ ++LDFLAGS = @LDFLAGS@ + HAVE_SODIUM = @HAVE_SODIUM@ +diff --git a/mk/libraries.mk b/mk/libraries.mk +index 3cd7a53..f7bd015 100644 +--- a/mk/libraries.mk ++++ b/mk/libraries.mk +@@ -88,3 +88,3 @@ define build-library + $$($(1)_PATH): $$($(1)_OBJS) $$(_libs) | $$(_d)/ +- $$(trace-ld) $(CXX) -o $$(abspath $$@) -shared $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$($(1)_LDFLAGS_PROPAGATED) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE)) $$($(1)_LDFLAGS_UNINSTALLED) ++ $$(trace-ld) $(CXX) -o $$(abspath $$@) -shared $$(LDFLAGS) $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$($(1)_LDFLAGS_PROPAGATED) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE)) $$($(1)_LDFLAGS_UNINSTALLED) + +@@ -102,3 +102,3 @@ define build-library + $$($(1)_INSTALL_PATH): $$($(1)_OBJS) $$(_libs_final) | $(DESTDIR)$$($(1)_INSTALL_DIR)/ +- $$(trace-ld) $(CXX) -o $$@ -shared $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$($(1)_LDFLAGS_PROPAGATED) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE_INSTALLED)) ++ $$(trace-ld) $(CXX) -o $$@ -shared $$(LDFLAGS) $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$($(1)_LDFLAGS_PROPAGATED) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE_INSTALLED)) + +diff --git a/mk/programs.mk b/mk/programs.mk +index 3ac6449..f553ce2 100644 +--- a/mk/programs.mk ++++ b/mk/programs.mk +@@ -34,3 +34,3 @@ define build-program + $$($(1)_PATH): $$($(1)_OBJS) $$(_libs) | $$(_d)/ +- $$(trace-ld) $(CXX) -o $$@ $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE)) ++ $$(trace-ld) $(CXX) -o $$@ $$(LDFLAGS) $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE)) + +@@ -48,3 +48,3 @@ define build-program + $(DESTDIR)$$($(1)_INSTALL_PATH): $$($(1)_OBJS) $$(_libs_final) | $(DESTDIR)$$($(1)_INSTALL_DIR)/ +- $$(trace-ld) $(CXX) -o $$@ $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE_INSTALLED)) ++ $$(trace-ld) $(CXX) -o $$@ $$(LDFLAGS) $$(GLOBAL_LDFLAGS) $$($(1)_OBJS) $$($(1)_LDFLAGS) $$(foreach lib, $$($(1)_LIBS), $$($$(lib)_LDFLAGS_USE_INSTALLED)) + diff --git a/sys-apps/nix/files/nix-1.11.6-systemd.patch b/sys-apps/nix/files/nix-1.11.6-systemd.patch new file mode 100644 index 000000000000..f890ee6f0470 --- /dev/null +++ b/sys-apps/nix/files/nix-1.11.6-systemd.patch @@ -0,0 +1,10 @@ +Make 'nix-daemon' a goof unit for 'systemctl enable nix-daemon.service'. +diff --git a/misc/systemd/nix-daemon.service.in b/misc/systemd/nix-daemon.service.in +index 5fc04a3..2565520 100644 +--- a/misc/systemd/nix-daemon.service.in ++++ b/misc/systemd/nix-daemon.service.in +@@ -9 +9,4 @@ ExecStart=@@bindir@/nix-daemon nix-daemon --daemon + KillMode=process ++ ++[Install] ++WantedBy=multi-user.target diff --git a/sys-apps/nix/files/nix-daemon.initd b/sys-apps/nix/files/nix-daemon.initd new file mode 100644 index 000000000000..1fd42734c0a8 --- /dev/null +++ b/sys-apps/nix/files/nix-daemon.initd @@ -0,0 +1,15 @@ +#!/sbin/openrc-run +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start --quiet --background --exec /usr/bin/nix-daemon + eend ${?} +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop --quiet --exec /usr/bin/nix-daemon + eend ${?} +} |