Skip to content

Commit d3f1383

Browse files
committed
system/nix: Some extra hardcoded assurance.
I realized late that it's started to spam root partition, again. I'm not really happy with this, not at all; first patch updated. Signed-off-by: Pouria Rezaei <[email protected]>
1 parent 5115b34 commit d3f1383

File tree

2 files changed

+20
-7
lines changed

2 files changed

+20
-7
lines changed

system/nix/fix_nix_options.patch

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,30 @@
11
diff --git a/doc/manual/local.mk b/doc/manual/local.mk
2-
index abdfd6a..dea46f3 100644
2+
index abdfd6a..f1cec77 100644
33
--- a/doc/manual/local.mk
44
+++ b/doc/manual/local.mk
5-
@@ -32,7 +32,7 @@ dummy-env = env -i \
6-
NIX_STATE_DIR=/dummy \
5+
@@ -25,14 +25,16 @@ clean-files += $(d)/*.1 $(d)/*.5 $(d)/*.8
6+
7+
# Provide a dummy environment for nix, so that it will not access files outside the macOS sandbox.
8+
# Set cores to 0 because otherwise nix show-config resolves the cores based on the current machine
9+
+dum_DIR := $(realpath $(nix_DIR))
10+
+
11+
dummy-env = env -i \
12+
- HOME=/dummy \
13+
- NIX_CONF_DIR=/dummy \
14+
- NIX_SSL_CERT_FILE=/dummy/no-ca-bundle.crt \
15+
- NIX_STATE_DIR=/dummy \
16+
+ HOME=$(dum_DIR)/dummy \
17+
+ NIX_CONF_DIR=$(dum_DIR)/dummy \
18+
+ NIX_SSL_CERT_FILE=$(dum_DIR)/dummy/no-ca-bundle.crt \
19+
+ NIX_STATE_DIR=$(dum_DIR)/dummy \
720
NIX_CONFIG='cores = 0'
821

922
-nix-eval = $(dummy-env) $(bindir)/nix eval --experimental-features nix-command -I nix/corepkgs=corepkgs --store dummy:// --impure --raw
1023
+nix-eval = $(dummy-env) $(nix_DIR)/nix eval --experimental-features nix-command -I nix/corepkgs=corepkgs --store dummy:// --impure --raw
1124

1225
# re-implement mdBook's include directive to make it usable for terminal output and for proper @docroot@ substitution
1326
define process-includes
14-
@@ -96,52 +96,52 @@ $(d)/src/SUMMARY.md: $(d)/src/SUMMARY.md.in $(d)/src/command-ref/new-cli $(d)/sr
27+
@@ -96,52 +98,52 @@ $(d)/src/SUMMARY.md: $(d)/src/SUMMARY.md.in $(d)/src/command-ref/new-cli $(d)/sr
1528
@cp $< $@
1629
@$(call process-includes,$@,$@)
1730

@@ -79,10 +92,10 @@ index abdfd6a..dea46f3 100644
7992

8093
# Generate the HTML manual.
8194
diff --git a/doc/manual/local.mk b/doc/manual/local.mk
82-
index dea46f3..422d531 100644
95+
index b4aba08..daed407 100644
8396
--- a/doc/manual/local.mk
8497
+++ b/doc/manual/local.mk
85-
@@ -174,22 +174,22 @@ doc/manual/generated/man1/nix3-manpages: $(d)/src/command-ref/new-cli
98+
@@ -176,22 +176,22 @@ doc/manual/generated/man1/nix3-manpages: $(d)/src/command-ref/new-cli
8699
@touch $@
87100

88101
$(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/contributing/experimental-feature-descriptions.md $(d)/src/command-ref/conf-file.md $(d)/src/language/builtins.md $(d)/src/language/builtin-constants.md

system/nix/nix.SlackBuild

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ find -L . \
102102
# root partition is bad, m'kay? (Updated).
103103
# - The above patch was added thanks to Pragmatic Cypher, along with
104104
# mdbook patch to make it disabled.
105-
# - Added global CFLAGS.
105+
# - Added global CFLAGS
106106
# - Changed to ignore offset, since function hasn't still implemented
107107
# in Slackware 15's sqlite.
108108
# - Fixed missing -lrapidcheck flag.

0 commit comments

Comments
 (0)