summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorHilton Chain <hako@ultrarare.space>2024-11-20 07:41:06 +0800
committerHilton Chain <hako@ultrarare.space>2024-12-31 10:56:34 +0800
commit5ce59e0413510098f92e4b824d2a24b97ad2e4c9 (patch)
treec8b24010320c7a5ccb4c03c759f148b009e456c3 /doc
parent3ef8c9307ce10ca59af9bcf84161a88fd08310e7 (diff)
build-system: zig: Support Zig package manager.
* guix/build-system/zig.scm (zig-build,zig-cross-build) [#:install-source?,#:skip-build?]: New arguments. [#:tests?]: Honor #:skip-build?. * guix/build/zig-build-system.scm (zig-source-install-path) (zig-input-install-path,unpack-dependencies): New procedures. (%standard-phases): Add 'unpack-dependencies. (build,install): Honor #:skip-build?. * doc/guix.texi (Build Systems)[zig-build-system]: Update documentation. * gnu/packages/zig.scm (zig-0.9)[native-search-paths]: Add GUIX_ZIG_PACKAGE_PATH. Use search paths defined in (guix search-paths). (add-build.zig.zon,rename-zig-dependencies): New procedures. * gnu/packages/ncdu.scm (ncdu)[arguments]: Don't install source. * gnu/packages/zig-xyz.scm (river,tigerbeetle,zig-zls)[arguments]: Likewise.
Diffstat (limited to 'doc')
-rw-r--r--doc/guix.texi35
1 files changed, 24 insertions, 11 deletions
diff --git a/doc/guix.texi b/doc/guix.texi
index c58468b910..924f13f0f6 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -10190,17 +10190,30 @@ build system (@command{zig build} command).
Selecting this build system adds @code{zig} to the package inputs, in
addition to the packages of @code{gnu-build-system}.
-There is no @code{configure} phase because Zig packages typically do not
-need to be configured. The @code{#:zig-build-flags} parameter is a list of
-flags that are passed to the @code{zig} command during the build. The
-@code{#:zig-test-flags} parameter is a list of flags that are passed to the
-@code{zig test} command during the @code{check} phase. The default compiler
-package can be overridden with the @code{#:zig} argument.
-
-The optional @code{zig-release-type} parameter declares the type of release.
-Possible values are: @code{safe}, @code{fast}, or @code{small}. The default
-value is @code{#f}, which causes the release flag to be omitted from the
-@code{zig} command. That results in a @code{debug} build.
+This build system by default installs package source to output. This
+behavior can be disabled by setting @code{#:install-source?} parameter
+to @code{#f}.
+
+For packages that don't install anything and don't come with a test
+suite (likely library packages to be used by other Zig packages), you
+can set @code{#:skip-build?} parameter to @code{#t}, which skips
+@code{build} and @code{check} phases.
+
+The @code{configure} phase sets up environment for @command{zig build}.
+You need to add custom phases after it if you want to invoke
+@command{zig}.
+
+The @code{#:zig-build-flags} parameter is a list of flags that are
+passed to @command{zig build} in @code{build} phase. The
+@code{#:zig-test-flags} parameter is a list of flags that are passed to
+@command{zig build test} in @code{check} phase. The default compiler
+package can be overridden with the @code{#:zig} parameter.
+
+The optional @code{#:zig-release-type} parameter declares the type of
+release. Possible values are: @code{"safe"}, @code{"fast"}, or
+@code{"small"}. The default value is @code{#f}, which causes the
+release flag to be omitted from the @code{zig} command and results in a
+@code{"debug"} build.
@end defvar
@defvar scons-build-system