ziglang / zig

General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software.

Home Page:https://ziglang.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Struggles building on mac m1 & trying to change & test std lib.

dmurph opened this issue · comments

Zig Version

0.14.0-89942ebd03b2943cbbe84b575a024e156ca5bf52

Steps to Reproduce and Observed Behavior

  1. Attempt to build on mac
    1. Get -lzstd problem output
    2. Solve by adding -DZIG_STATIC_ZSTD=ON then everything works. This should be added to the wiki
  2. Make a change to something in the std lib
    1. Fail to figure out how to do this. Commands attempted:

(

stage3/bin/zig  build --override-std-dir ../lib/std --build-file ../build.zig test -Dskip-release
 stage3/bin/zig test ../lib/std/testing.zig
stage3/bin/zig test ../lib/std/testing.zig --override-std-dir ../lib/std
build/stage3/bin/zig test lib/std/testing.zig
build/stage3/bin/zig build test --zig-lib-dir lib --test_filters testing.zig
stage3/bin/zig test ../lib/std/testing.zig --zig-lib-dir lib --main-pkg-path lib/std
stage3/bin/zig --override-std-dir ../lib/std build --build-file ../build.zig test -Dskip-release

I couldn't get any of these to work.....

Expected Behavior

The documentation should probably show how to build on Mac & it would be great for it to show how to make changes & test those changes in things like the std lib.