diff options
| author | user <user@clank> | 2026-09-02 12:55:24 +0200 |
|---|---|---|
| committer | user <user@clank> | 2026-09-02 12:55:24 +0200 |
| commit | 89dc98578d32cd9784869cd499ae7b9ea51da272 (patch) | |
| tree | 8f9da270d6bdaeb4effaa7cede6a1a88b24a60a0 | |
| parent | web: cleanup (diff) | |
| download | slosh-89dc98578d32cd9784869cd499ae7b9ea51da272.tar.gz slosh-89dc98578d32cd9784869cd499ae7b9ea51da272.tar.xz slosh-89dc98578d32cd9784869cd499ae7b9ea51da272.zip | |
find zig on PATH instead of hardcoding ~/zig-0.16.0/zig
| -rw-r--r-- | Makefile | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -3,7 +3,12 @@ # zig is the C compiler: it is already required to build libghostty-vt, and it # gives us static musl linking and cross-compilation for free (D12). -ZIG ?= $(HOME)/zig-0.16.0/zig +# Honour an explicit ZIG=... on the command line or in the environment; +# otherwise use whatever `zig` is on $PATH. +ZIG ?= $(shell command -v zig 2>/dev/null) +ifeq ($(ZIG),) + $(error zig not found on $$PATH -- install it or pass ZIG=/path/to/zig) +endif CC := $(ZIG) cc VT := vendor/libghostty-vt VT_OUT := $(VT)/zig-out |
