Skip to content

Commit

Permalink
system/nix: Updated to 2.14.1.
Browse files Browse the repository at this point in the history
Signed-off-by: Pouria Rezaei <[email protected]>
  • Loading branch information
RSKYS committed Jun 29, 2024
1 parent 3cbf5d4 commit 466df17
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 13 deletions.
50 changes: 41 additions & 9 deletions system/nix/fix_nix_options.patch
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
diff --git a/doc/manual/local.mk b/doc/manual/local.mk
index 66a8cb7..d2db2b3 100644
index f43510b..1e1e62d 100644
--- a/doc/manual/local.mk
+++ b/doc/manual/local.mk
@@ -24,7 +24,7 @@ dummy-env = env -i \
Expand All @@ -11,19 +11,24 @@ index 66a8cb7..d2db2b3 100644

$(d)/%.1: $(d)/src/command-ref/%.md
@printf "Title: %s\n\n" "$$(basename $@ .1)" > $^.tmp
@@ -48,31 +48,31 @@ $(d)/src/SUMMARY.md: $(d)/src/SUMMARY.md.in $(d)/src/command-ref/new-cli
@@ -48,29 +48,29 @@ $(d)/src/SUMMARY.md: $(d)/src/SUMMARY.md.in $(d)/src/command-ref/new-cli
$(trace-gen) cat doc/manual/src/SUMMARY.md.in | while IFS= read line; do if [[ $$line = @manpages@ ]]; then cat doc/manual/src/command-ref/new-cli/SUMMARY.md; else echo "$$line"; fi; done > [email protected]
@mv [email protected] $@

-$(d)/src/command-ref/new-cli: $(d)/nix.json $(d)/generate-manpage.nix $(bindir)/nix
+$(d)/src/command-ref/new-cli: $(d)/nix.json $(d)/generate-manpage.nix $(nix_DIR)/nix
@rm -rf $@
$(trace-gen) $(nix-eval) --write-to $@ --expr 'import doc/manual/generate-manpage.nix { command = builtins.readFile $<; renderLinks = true; }'
$(trace-gen) $(nix-eval) --write-to [email protected] --expr 'import doc/manual/generate-manpage.nix { toplevel = builtins.readFile $<; }'
@# @docroot@: https://nixos.org/manual/nix/unstable/contributing/hacking.html#docroot-variable
$(trace-gen) sed -i [email protected]/*.md -e 's^@docroot@^../..^g'
@mv [email protected] $@

-$(d)/src/command-ref/conf-file.md: $(d)/conf-file.json $(d)/generate-options.nix $(d)/src/command-ref/conf-file-prefix.md $(bindir)/nix
+$(d)/src/command-ref/conf-file.md: $(d)/conf-file.json $(d)/generate-options.nix $(d)/src/command-ref/conf-file-prefix.md $(nix_DIR)/nix
@cat doc/manual/src/command-ref/conf-file-prefix.md > [email protected]
$(trace-gen) $(nix-eval) --expr 'import doc/manual/generate-options.nix (builtins.fromJSON (builtins.readFile $<))' >> [email protected]
@# @docroot@: https://nixos.org/manual/nix/unstable/contributing/hacking.html#docroot-variable
$(trace-gen) $(nix-eval) --expr 'import doc/manual/generate-options.nix (builtins.fromJSON (builtins.readFile $<))' \
| sed -e 's^@docroot@^..^g'>> [email protected]
@mv [email protected] $@

-$(d)/nix.json: $(bindir)/nix
Expand All @@ -41,7 +46,9 @@ index 66a8cb7..d2db2b3 100644
-$(d)/src/language/builtins.md: $(d)/builtins.json $(d)/generate-builtins.nix $(d)/src/language/builtins-prefix.md $(bindir)/nix
+$(d)/src/language/builtins.md: $(d)/builtins.json $(d)/generate-builtins.nix $(d)/src/language/builtins-prefix.md $(nix_DIR)/nix
@cat doc/manual/src/language/builtins-prefix.md > [email protected]
$(trace-gen) $(nix-eval) --expr 'import doc/manual/generate-builtins.nix (builtins.fromJSON (builtins.readFile $<))' >> [email protected]
@# @docroot@: https://nixos.org/manual/nix/unstable/contributing/hacking.html#docroot-variable
$(trace-gen) $(nix-eval) --expr 'import doc/manual/generate-builtins.nix (builtins.fromJSON (builtins.readFile $<))' \
@@ -78,8 +78,8 @@ $(d)/src/language/builtins.md: $(d)/builtins.json $(d)/generate-builtins.nix $(d
@cat doc/manual/src/language/builtins-suffix.md >> [email protected]
@mv [email protected] $@

Expand All @@ -53,14 +60,39 @@ index 66a8cb7..d2db2b3 100644

# Generate the HTML manual.
diff --git a/doc/manual/local.mk b/doc/manual/local.mk
index 66a8cb7..abf0d2c 100644
index 1e1e62d..3978847 100644
--- a/doc/manual/local.mk
+++ b/doc/manual/local.mk
@@ -102,6 +102,6 @@ doc/manual/generated/man1/nix3-manpages: $(d)/src/command-ref/new-cli
@@ -109,12 +109,12 @@ doc/manual/generated/man1/nix3-manpages: $(d)/src/command-ref/new-cli
@touch $@

$(docdir)/manual/index.html: $(MANUAL_SRCS) $(d)/book.toml $(d)/anchors.jq $(d)/custom.css $(d)/src/SUMMARY.md $(d)/src/command-ref/new-cli $(d)/src/command-ref/conf-file.md $(d)/src/language/builtins.md
- $(trace-gen) RUST_LOG=warn mdbook build doc/manual -d $(DESTDIR)$(docdir)/manual
+ # $(trace-gen) RUST_LOG=warn mdbook build doc/manual -d $(DESTDIR)$(docdir)/manual
- $(trace-gen) \
- set -euo pipefail; \
- RUST_LOG=warn mdbook build doc/manual -d $(DESTDIR)$(docdir)/manual.tmp 2>&1 \
- | { grep -Fv "because fragment resolution isn't implemented" || :; }
- @rm -rf $(DESTDIR)$(docdir)/manual
- @mv $(DESTDIR)$(docdir)/manual.tmp/html $(DESTDIR)$(docdir)/manual
- @rm -rf $(DESTDIR)$(docdir)/manual.tmp
+ # $(trace-gen) \
+ # set -euo pipefail; \
+ # RUST_LOG=warn mdbook build doc/manual -d $(DESTDIR)$(docdir)/manual.tmp 2>&1 \
+ # | { grep -Fv "because fragment resolution isn't implemented" || :; }
+ # @rm -rf $(DESTDIR)$(docdir)/manual
+ # @mv $(DESTDIR)$(docdir)/manual.tmp/html $(DESTDIR)$(docdir)/manual
+ # @rm -rf $(DESTDIR)$(docdir)/manual.tmp

endif
diff --git a/Makefile b/Makefile
index 8675c99..12edef4 100644
--- a/Makefile
+++ b/Makefile
@@ -34,6 +34,8 @@ else
GLOBAL_CXXFLAGS += -O0 -U_FORTIFY_SOURCE
endif

+GLOBAL_CFLAGS += $(CPPFLAGS)
+
include mk/lib.mk

GLOBAL_CXXFLAGS += -g -Wall -include config.h -std=c++2a -I src
3 changes: 2 additions & 1 deletion system/nix/nix.SlackBuild
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
cd $(dirname $0) ; CWD=$(pwd)

PRGNAM=nix
VERSION=${VERSION:-2.11.1}
VERSION=${VERSION:-2.14.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
Expand Down Expand Up @@ -102,6 +102,7 @@ find -L . \
# root partition is bad, m'kay? (Updated)
# - The above patch was added thanks to Pragmatic Cypher, along with
# mdbook patch to make it disabled.
# - Added global CFLAGS
patch -p1 < $CWD/fix_nix_options.patch

autoreconf -vfim
Expand Down
6 changes: 3 additions & 3 deletions system/nix/nix.info
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
PRGNAM="nix"
VERSION="2.11.1"
VERSION="2.14.1"
HOMEPAGE="http://nixos.org/nix"
DOWNLOAD="https://github.com/NixOS/nix/archive/2.11.1/nix-2.11.1.tar.gz"
MD5SUM="b103a11f6c6c4e9a4c8c135a02a7540a"
DOWNLOAD="https://github.com/NixOS/nix/archive/2.14.1/nix-2.14.1.tar.gz"
MD5SUM="a132c8cf9a246c6ceecb8625163beff0"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="gtest jq libeditline lowdown libcpuid nlohmann_json"
Expand Down

0 comments on commit 466df17

Please sign in to comment.