#!/usr/bin/env bash HERE=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &>/dev/null && pwd) fullbuild() { rm -fr build mkdir build pushd build CC=clang-$1 CXX=clang++-$1 cmake .. make -j"$(nproc)" install popd } # zig2 halfbuild() { sed -i '/^add_custom_target(stage3/,/^)$/d' CMakeLists.txt rm -fr build mkdir build pushd build CC=clang-$1 CXX=clang++-$1 cmake .. make -j"$(nproc)" popd } # commit e7d28344fa3ee81d6ad7ca5ce1f83d50d8502118 # Merge: 817cf6a82e 20d86d9c63 # Author: Andrew Kelley # Date: 2022-12-07T01:52:39+02:00 # # Merge pull request #13560 from ziglang/wasi-bootstrap # # Nuke the C++ implementation of Zig from orbit using WASI # STEP00_A=e7d28344fa3ee81d6ad7ca5ce1f83d50d8502118 # commit 3ba916584db5485c38ebf2390e8d22bc6d81bf8e # Author: Andrew Kelley # Date: 2022-11-05T03:47:19+02:00 # # actually remove stage1 # STEP00_B=3ba916584db5485c38ebf2390e8d22bc6d81bf8e # commit 28514476ef8c824c3d189d98f23d0f8d23e496ea # Author: Andrew Kelley # Date: 2022-11-01T05:29:55+02:00 # # remove `-fstage1` option # # After this commit, the self-hosted compiler does not offer the option to # use stage1 as a backend anymore. # STEP00_C=28514476ef8c824c3d189d98f23d0f8d23e496ea step00() { git reset --hard git clean -ffxd git checkout $STEP00_A git revert --no-edit $STEP00_B git revert --no-edit -X theirs $STEP00_C git mv stage1/config.zig.in src sed -i '/have_stage1/ s/false/true/' src/config.zig.in git checkout $STEP00_C~1 build.zig CMakeLists.txt echo "Building the C++ (stage1) implementation" fullbuild 15 echo "C++ implementation in build/stage3/bin/zig. Will build zig1.wasm.zst." git reset --hard git checkout $STEP00_A build/stage3/bin/zig build update-zig1 echo "stage1/zig1.wasm.zst built. Bootstrapping zig with it." } # commit 9d93b2ccf11f584320a2c5209dd2d94705167695 # Author: Veikka Tuominen # Date: 2022-12-08T19:52:05+02:00 # # Eliminate `BoundFn` type from the language # # Closes #9484 # STEP01=9d93b2ccf11f584320a2c5209dd2d94705167695 STEP01_=0.10.0-675-g9d93b2ccf1 step01() { rm -fr "../zig-$STEP01_" git archive --prefix=zig-$STEP01_/ $STEP01 | tar -C .. -x { pushd "../zig-$STEP01_" cp "$OLDPWD/stage1/zig1.wasm.zst" stage1/ patch -p1 <"$HERE/0.10.0-675-g9d93b2ccf1-TypeOf-hack.patch" halfbuild 15 build/zig2 build update-zig1 popd } } # commit d10fd78d4615f329141f5c19f893039d56aff425 # Author: Andrew Kelley # Date: 2022-12-10T21:54:24+02:00 # # update zig1.wasm # # This includes the latest changes from master branch with fixes to the C # backend that affect aarch64-windows which are necessary to build from # source on this target. # STEP02=d10fd78d4615f329141f5c19f893039d56aff425 STEP02_=0.10.0-722-gd10fd78d46 step02() { rm -fr "../zig-$STEP02_" git archive --prefix=zig-$STEP02_/ $STEP02 | tar -C .. -x { pushd "../zig-$STEP02_" zstd -cd ../zig-$STEP01_/stage1/zig1.wasm.zst >stage1/zig1.wasm halfbuild 15 build/zig2 build update-zig1 popd } } # commit 7b2a936173165002105ba5e76bed69654e132fea # Author: Veikka Tuominen # Date: 2022-12-12T15:32:37+02:00 # # remove `stack` option from `@call` # STEP03=7b2a936173165002105ba5e76bed69654e132fea STEP03_=0.10.0-747-g7b2a936173 step03() { rm -fr "../zig-$STEP03_" git archive --prefix=zig-$STEP03_/ $STEP03 | tar -C .. -x { pushd "../zig-$STEP03_" patch -p1 <"$HERE/0.10.0-747-g7b2a936173-CallOptions.patch" ../zig-$STEP02_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 08b2d491bcd8c79c68495267cc71967661caea1e # Author: Veikka Tuominen # Date: 2022-12-12T15:32:37+02:00 # # update usages of `@call` # STEP04=08b2d491bcd8c79c68495267cc71967661caea1e STEP04_=0.10.0-748-g08b2d491bc step04() { rm -fr "../zig-$STEP04_" git archive --prefix=zig-$STEP04_/ $STEP04 | tar -C .. -x { pushd "../zig-$STEP04_" cp ../zig-$STEP03_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 build/zig2 build update-zig1 popd } } # commit 35184bff75420f405cb703c9cf86b196843b9a94 (HEAD) # Author: r00ster91 # Date: 2022-12-13T23:30:06+02:00 # # std.builtin: rename Type.UnionField and Type.StructField's field_type to type # STEP05=aac2d6b56f32134ea32fb3d984e3fcdfddd8aaf6 STEP05_=0.10.0-851-gaac2d6b56f step05() { rm -fr "../zig-$STEP05_" git archive --prefix=zig-$STEP05_/ $STEP05 | tar -C .. -x { pushd "../zig-$STEP05_" cp ../zig-$STEP04_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 popd } } # commit 2a5e1426aa9469fadb78e837d0100d689213b034 # Author: Veikka Tuominen # Date: 2022-12-16T19:44:25+02:00 # # update zig1.wasm to builtin.Type field changes # STEP06=2a5e1426aa9469fadb78e837d0100d689213b034 STEP06_=0.10.0-853-g2a5e1426aa step06() { rm -fr "../zig-$STEP06_" git archive --prefix=zig-$STEP06_/ $STEP06 | tar -C .. -x { pushd "../zig-$STEP06_" ../zig-$STEP05_/build/zig2 build update-zig1 popd } } # commit 54160e7f6aecb4628df633ceaef4c6d956429a3d # Author: Veikka Tuominen # Date: 2022-12-21T14:33:02+02:00 # # Sema: make overflow arithmetic builtins return tuples # STEP07=54160e7f6aecb4628df633ceaef4c6d956429a3d STEP07_=0.10.0-961-g54160e7f6a step07() { rm -fr "../zig-$STEP07_" git archive --prefix=zig-$STEP07_/ $STEP07 | tar -C .. -x { pushd "../zig-$STEP07_" cp ../zig-$STEP06_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 popd } } # commit 622311fb9ac7ee6d93dcb8cda4b608751f7e092a # Author: Veikka Tuominen # Date: 2022-12-21T16:40:30+02:00 # # update uses of overflow arithmetic builtins # STEP08=622311fb9ac7ee6d93dcb8cda4b608751f7e092a STEP08_=0.10.0-962-g622311fb9a step08() { rm -fr "../zig-$STEP08_" git archive --prefix=zig-$STEP08_/ $STEP08 | tar -C .. -x { pushd "../zig-$STEP08_" ../zig-$STEP07_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit a43fdc1620fa24c8c606f748505766bfd53d1049 # Author: kcbanner # Date: 2022-12-09T02:50:08+02:00 # # cbe: first set of changes for msvc compatibility # STEP09=a43fdc1620fa24c8c606f748505766bfd53d1049 STEP09_=0.10.0-1027-ga43fdc1620 step09() { rm -fr "../zig-$STEP09_" git archive --prefix=zig-$STEP09_/ $STEP09 | tar -C .. -x { pushd "../zig-$STEP09_" cp ../zig-$STEP08_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 popd } } # commit 4c1007fc044689b8cbc20634d73debb43df8efe1 # Merge: 4172c29166 23b1544f6c # Author: Andrew Kelley # Date: 2023-01-02T23:11:17+02:00 # # Merge pull request #14002 from kcbanner/cbe_msvc_compatibility # STEP10=4c1007fc044689b8cbc20634d73debb43df8efe1 STEP10_=0.10.0-1073-g4c1007fc04 step10() { rm -fr "../zig-$STEP10" git archive --prefix=zig-$STEP10_/ $STEP10 | tar -C .. -x { pushd "../zig-$STEP10_" ../zig-$STEP09_/build/zig2 build --zig-lib-dir lib update-zig1 halfbuild 15 popd } } #commit a9b68308b9eeb494524e2b7ab0d63cfa6b623cd0 #Author: Casey Banner #Date: 2023-01-26T07:45:40+02:00 # # cbe: fixes for tls, support for not linking libc, and enabling tests # STEP11=a9b68308b9eeb494524e2b7ab0d63cfa6b623cd0 STEP11_=0.10.0-1497-ga9b68308b9 step11() { rm -fr "../zig-$STEP11" git archive --prefix=zig-$STEP11_/ $STEP11 | tar -C .. -x { pushd "../zig-$STEP11_" ../zig-$STEP10_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit f16c10a86b7183e99e54a70344f4681211cd52bb # Author: Veikka Tuominen # Date: 2023-01-27T20:25:48+02:00 # # implement `@qualCast` # STEP12=f16c10a86b7183e99e54a70344f4681211cd52bb STEP12_=0.10.0-1506-gf16c10a86b step12() { rm -fr "../zig-$STEP12" # use the @qualCast implementation in src/, but remove usages in lib/ git archive --prefix=zig-$STEP12_/ $STEP12 | tar -C .. -x git archive --prefix=zig-$STEP12_/ $STEP12~1 lib | tar -C .. -x { pushd "../zig-$STEP12_" cp ../zig-$STEP11_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 7199d7c77715fe06606c5c89595e6852b3fa8c20 # Author: Veikka Tuominen # Date: 2023-02-13T16:19:17+02:00 # # split `@qualCast` into `@constCast` and `@volatileCast` # STEP13=7199d7c77715fe06606c5c89595e6852b3fa8c20 STEP13_=0.10.0-1638-g7199d7c777 step13() { rm -fr "../zig-$STEP13" # ditto as previous step: implementation here, usages from HEAD~1 git archive --prefix=zig-$STEP13_/ $STEP13 | tar -C .. -x git archive --prefix=zig-$STEP13_/ $STEP13~1 lib | tar -C .. -x { pushd "../zig-$STEP13_" patch -p1 <"$HERE/0.10.0-1638-g7199d7c777-re-add-qualCast.patch" cp ../zig-$STEP12_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 321ccbdc525ab0f5862e42378b962c10ec54e4a1 # Author: Andrew Kelley # Date: 2023-02-18T04:54:26+02:00 # # Sema: implement for_len # STEP14=321ccbdc525ab0f5862e42378b962c10ec54e4a1 STEP14_=0.10.0-1657-g321ccbdc52 step14() { rm -fr "../zig-$STEP14_" git archive --prefix=zig-$STEP14_/ $STEP14 | tar -C .. -x { pushd "../zig-$STEP14_" cp ../zig-$STEP13_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 popd } } # commit 0bb178bbb2451238a326c6e916ecf38fbc34cab1 # Merge: 346ec15c50 5fc6bbe71e # Author: Andrew Kelley # Date: 2023-02-19T17:10:59+02:00 # # Merge pull request #14671 from ziglang/multi-object-for # STEP15=0bb178bbb2451238a326c6e916ecf38fbc34cab1 STEP15_=0.10.0-1681-g0bb178bbb2 step15() { rm -fr "../zig-$STEP15_" git archive --prefix=zig-$STEP15_/ $STEP15 | tar -C .. -x { pushd "../zig-$STEP15_" ../zig-$STEP14_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 705d2a3c2cd94faf8e16c660b3b342d6fe900e55 # Author: mlugg # Date: 2023-02-17T03:44:08+02:00 # # Implement new module CLI # STEP16=705d2a3c2cd94faf8e16c660b3b342d6fe900e55 STEP16_=0.10.0-1712-g705d2a3c2c step16() { rm -fr "../zig-$STEP16" git archive --prefix=zig-$STEP16_/ $STEP16 | tar -C .. -x { pushd "../zig-$STEP16_" cp ../zig-$STEP15_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 popd } } # commit 09a84c8384dffc7884528947b879f32d93c1bd90 # Author: mlugg # Date: 2023-02-17T08:20:52+02:00 # # Update std.Build to new module CLI, update zig1 and CMakeLists # STEP17=09a84c8384dffc7884528947b879f32d93c1bd90 STEP17_=0.10.0-1713-g09a84c8384 step17() { rm -fr "../zig-$STEP17" git archive --prefix=zig-$STEP17_/ $STEP17 | tar -C .. -x { pushd "../zig-$STEP17_" ../zig-$STEP16_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit c839c180ef1686794c039fc6d3c20a8716e87357 # Author: Andrew Kelley # Date: 2023-03-05T21:46:12+02:00 # # stage2: add zig_backend to ZIR cache namespace # STEP18=c839c180ef1686794c039fc6d3c20a8716e87357 STEP18_=0.10.0-1888-gc839c180ef step18() { rm -fr "../zig-$STEP18_" git archive --prefix=zig-$STEP18_/ $STEP18 | tar -C .. -x { pushd "../zig-$STEP18_" cp ../zig-$STEP17_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 15 popd } } # commit ac1b0e832b4b9d151098050e1d29e28a568e215c # Merge: 2641feb9b9 8558983c86 # Author: Andrew Kelley # Date: 2023-03-06T08:29:56+02:00 # # Merge pull request #14799 from ziglang/update-zig1 # # `@trap` fixups # STEP19=ac1b0e832b4b9d151098050e1d29e28a568e215c STEP19_=0.10.0-1891-gac1b0e832b step19() { rm -fr "../zig-$STEP19_" git archive --prefix=zig-$STEP19_/ $STEP19 | tar -C .. -x { pushd "../zig-$STEP19_" ../zig-$STEP18_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit fc9ab4144cc577e5293e685af2d53ac1cb3415ce # Author: Andrew Kelley # Date: 2023-04-06T09:22:29+03:00 # # update libcxx to LLVM 16.0.1 # STEP20=fc9ab4144cc577e5293e685af2d53ac1cb3415ce STEP20_=0.10.0-2440-gfc9ab4144c step20() { rm -fr "../zig-$STEP20_" git archive --prefix=zig-$STEP20_/ $STEP20 | tar -C .. -x { pushd "../zig-$STEP20_" cp ../zig-$STEP19_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 popd } } # commit d3a237a98c5a2ccf72a774b5f93425c02fea4bea # Merge: 1728d92f60 3c3cee2cfa # Author: Andrew Kelley # Date: 2023-04-11T18:54:43+03:00 # # Merge pull request #15234 from ziglang/remove-legacy-build-api # # remove --enable-cache option; std.Build.CompileStep: remove output_dir # STEP21=d3a237a98c5a2ccf72a774b5f93425c02fea4bea STEP21_=0.10.0-2558-gd3a237a98c step21() { rm -fr "../zig-$STEP21_" git archive --prefix=zig-$STEP21_/ $STEP21 | tar -C .. -x { pushd "../zig-$STEP21_" cp ../zig-$STEP20_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 popd } } # commit e2fe1907ecac075e4d4a37776359144318b6055a # Author: Andrew Kelley # Date: 2023-04-13T07:03:36+03:00 # # add c_char type # STEP22=e2fe1907ecac075e4d4a37776359144318b6055a STEP22_=0.10.0-2566-ge2fe1907ec step22() { rm -fr "../zig-$STEP22_" git archive --prefix=zig-$STEP22_/ $STEP22 | tar -C .. -x git archive --prefix=zig-$STEP22_/ $STEP22~1 lib/std/start.zig | tar -C .. -x { pushd "../zig-$STEP22_" ../zig-$STEP21_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 31738de2817f7932fa9237492f20fb736bc07dd3 (HEAD, replaced) # Merge: 335a6bb0b2 4f3ce7411e # Author: Jakub Konka # Date: Thu Apr 13 13:53:01 2023 +0200 # # Merge pull request #15184 from jacobly0/x86_64 # STEP23=31738de2817f7932fa9237492f20fb736bc07dd3 STEP23_=0.10.0-2571-g31738de281 step23() { rm -fr "../zig-$STEP23_" git archive --prefix=zig-$STEP23_/ $STEP23 | tar -C .. -x { pushd "../zig-$STEP23_" cp ../zig-$STEP22_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 build/zig2 build update-zig1 popd } } # commit 35d82d31be3d2f2611049f41dc2616f898d70871 # Author: Matthew Lugg # Date: 2023-04-15T00:32:31+03:00 # # Add `@inComptime` builtin # STEP24=35d82d31be3d2f2611049f41dc2616f898d70871 STEP24_=0.10.0-2797-g35d82d31be step24() { rm -fr "../zig-$STEP24_" git archive --prefix=zig-$STEP24_/ $STEP24 | tar -C .. -x git archive --prefix=zig-$STEP24_/ $STEP24~1 lib | tar -C .. -x { pushd "../zig-$STEP24_" cp ../zig-$STEP23_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 build/zig2 build update-zig1 popd } } # commit a8de15f66a51d273cefa07eed0d8fd2952e92387 # Author: Andrew Kelley # Date: Mon Apr 24 13:29:42 2023 -0700 # # update zig1.wasm # # Needed due to the compiler depending on standard library APIs such as # ArrayList that contain `@memset` and `@memcpy` calls in them. The number # of parameters changed, so this is necessary for the compiler to build. # STEP25_A=a8de15f66a51d273cefa07eed0d8fd2952e92387 # One commit before changing @memset@/@memcpy semantics: # # commit 8d88dcdc61c61e3410138f4402482131f5074a80 # Author: David Carlier # Date: 2023-04-23T02:47:29+03:00 # # std.c: adding mincore for freebsd # STEP25_B=8d88dcdc61c61e3410138f4402482131f5074a80 STEP25_=0.10.0-2838-ga8de15f66a step25() { rm -fr "../zig-$STEP25_" git archive --prefix=zig-$STEP25_/ $STEP25_A | tar -C .. -x mv ../zig-$STEP25_/lib ../zig-$STEP25_/lib.bk git archive --prefix=zig-$STEP25_/ $STEP25_B lib | tar -C .. -x { pushd "../zig-$STEP25_" cp ../zig-$STEP24_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 rm -fr lib mv lib.bk lib build/zig2 build update-zig1 popd } } # commit 22c6b6c9a9378aaca75c83c2182a6d94298f6bc2 # Author: Matthew Lugg # Date: 2023-06-14T03:09:23+03:00 # # Update zig1.wasm # # This is needed in order to remove math.{min,max} from std in favour of # the builtins, since the builtins need the behavior fix from the previous # commit. # # Note from Andrew: I updated this commit with zig1.wasm built by me. # STEP26=22c6b6c9a9378aaca75c83c2182a6d94298f6bc2 STEP26_=0.10.0-3660-g22c6b6c9a9 step26() { rm -fr "../zig-$STEP26_" git archive --prefix=zig-$STEP26_/ $STEP26 | tar -C .. -x { pushd "../zig-$STEP26_" cp ../zig-$STEP25_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 build/zig2 build update-zig1 popd } } # commit a6c8ee5231230947c928bbe1c6a39eb6e1bb9c5b # Author: Eric Joldasov # Date: 2023-06-14T17:27:03+03:00 # # compiler: rename "@XToY" to "@YFromX", zig fmt: rewrite them # STEP27=a6c8ee5231230947c928bbe1c6a39eb6e1bb9c5b STEP27_=0.10.0-3726-ga6c8ee5231 step27() { rm -fr "../zig-$STEP27_" git archive --prefix=zig-$STEP27_/ $STEP27 | tar -C .. -x { pushd "../zig-$STEP27_" ../zig-$STEP26_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit a4d1edac8d65e1aa4b565f6fb11ab78541d97efa # Author: Eric Joldasov # Date: 2023-06-15T10:43:59+03:00 # # stage1: update zig1.wasm after renaming "@XtoY" to "YfromX" # STEP28=a4d1edac8d65e1aa4b565f6fb11ab78541d97efa STEP28_=0.10.0-3728-ga4d1edac8d step28() { rm -fr "../zig-$STEP28_" git archive --prefix=zig-$STEP28_/ $STEP28 | tar -C .. -x { pushd "../zig-$STEP28_" cp ../zig-$STEP27_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 popd } } # commit be0c69957e7489423606023ad820599652a60e15 # Author: Matthew Lugg # Date: 2023-06-20T15:39:35+03:00 # # compiler: remove destination type from cast builtins # STEP29=be0c69957e7489423606023ad820599652a60e15 STEP29_=0.10.0-3807-gbe0c69957e step29() { rm -fr "../zig-$STEP29_" git archive --prefix=zig-$STEP29_/ $STEP29 | tar -C .. -x { pushd "../zig-$STEP29_" ../zig-$STEP28_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 21ac0beb436f49fe49c6982a872f2dc48e4bea5e # Author: Matthew Lugg # Date: 2023-06-23T21:55:31+03:00 # # update zig1.wasm # # Needed due to the breaking changes to casting builtins, which are used # by the compiler when building itself. # STEP30=21ac0beb436f49fe49c6982a872f2dc48e4bea5e STEP30_=0.10.0-3813-g21ac0beb43 step30() { rm -fr "../zig-$STEP30_" git archive --prefix=zig-$STEP30_/ $STEP30 | tar -C .. -x { pushd "../zig-$STEP30_" cp ../zig-$STEP29_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 build/zig2 build update-zig1 popd } } # commit 4bce7b1db964098e4a9163201fa3adcb26af6d97 # Author: antlilja # Date: 2023-07-06T20:47:13+03:00 # # Remove len parameter from splat builtin function # # Resolve the result type of the splat builtin instead of requiring a # length parameter. # STEP31=4bce7b1db964098e4a9163201fa3adcb26af6d97 STEP31_=0.10.0-3980-g4bce7b1db9 step31() { rm -fr "../zig-$STEP31_" git archive --prefix=zig-$STEP31_/ $STEP31 | tar -C .. -x { pushd "../zig-$STEP31_" cp ../zig-$STEP30_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 popd } } # commit 47d5bf26164b4ddb3228d17ae2158d1c29b8d040 # Author: Andrew Kelley # Date: 2023-07-13T01:50:57+03:00 # # update zig1.wasm # # Needed due to the breaking changes to `@splat` which are used by the # self-hosted compiler. STEP32=47d5bf26164b4ddb3228d17ae2158d1c29b8d040 STEP32_=0.10.0-3985-g47d5bf2616 step32() { rm -fr "../zig-$STEP32_" git archive --prefix=zig-$STEP32_/ $STEP32 | tar -C .. -x { pushd "../zig-$STEP32_" ../zig-$STEP31_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # tag 0.11.0 # Tagger: Andrew Kelley # Date: 2023-08-03T21:22:03+03:00 # # Release 0.11.0 # # commit 67709b638224ac03820226c6744d8b6ead59184c (tag: 0.11.0) # Author: Andrew Kelley # Date: 2023-08-03T21:22:03+03:00 # # Release 0.11.0 # # Note for packagers: I had problems building stage3 on a recent Linux # distribution due to a linker error See e8767d2b76ca8 for more details and # some advise on how to proceed/work around it. STEP33=67709b638224ac03820226c6744d8b6ead59184c STEP33_=0.11.0 step33() { rm -fr "../zig-$STEP33_" git archive --prefix=zig-$STEP33_/ $STEP33 | tar -C .. -x { pushd "../zig-$STEP33_" cp ../zig-$STEP32_/stage1/zig1.wasm stage1/zig1.wasm fullbuild 16 build/stage3/bin/zig build update-zig1 popd } } # commit 7a85ad151daece3d0bba3c8d23081502a0956c95 # Author: mlugg # Date: 2023-08-19T04:35:00+03:00 # # cbe: elide block result allocation for 0-bit types # # This logic already existed for the void type, but is also necessary for # other 0-bit types. Without it, we try to alloc a local for a 0-bit type # which gets translated to a local of type `void` which C doesn't like. STEP34=7a85ad151daece3d0bba3c8d23081502a0956c95 STEP34_=0.11.0-149-g7a85ad151d step34() { rm -fr "../zig-$STEP34_" git archive --prefix=zig-$STEP34_/ $STEP34 | tar -C .. -x { pushd "../zig-$STEP34_" ../zig-$STEP33_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 88f5315ddfc6eaf3e28433504ec046fb3252db7c # Author: mlugg # Date: 2023-08-31T16:30:58+03:00 # # compiler: implement destructuring syntax # STEP35=88f5315ddfc6eaf3e28433504ec046fb3252db7c STEP35_=0.11.0-384-g88f5315ddf step35() { rm -fr "../zig-$STEP35_" git archive --prefix=zig-$STEP35_/ $STEP35 | tar -C .. -x { pushd "../zig-$STEP35_" cp ../zig-$STEP34_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 build/zig2 build update-zig1 popd } } # commit a8d2ed806558cc1472f3a532169a4994abe17833 # Merge: 0345d78663 221295b7db # Author: Andrew Kelley # Date: 2023-09-22T19:38:41+03:00 # # Merge pull request #17172 from ziglang/ip-structs # # compiler: move struct types into InternPool proper # STEP36=a8d2ed806558cc1472f3a532169a4994abe17833 STEP36_=0.11.0-494-ga8d2ed8065 step36() { rm -fr "../zig-$STEP36_" git archive --prefix=zig-$STEP36_/ $STEP36 | tar -C .. -x { pushd "../zig-$STEP36_" cp ../zig-$STEP35_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 16 popd } } # commit 6bd54a1d3ebd8d997158c57057ba742824cf7e0c # Author: Andrew Kelley # Date: 2023-09-25T01:09:46+03:00 # # update zig1.wasm # # Notable changes in this update: # # 127198e58cb3dcf2d2287124cf15a23a7d3a9c02 fixes building zig2 artifact on # macOS Sonoma 14.0 (more specifically the SDK 14.0 linker). # # a8d2ed806558cc1472f3a532169a4994abe17833 fixed some alignment edge # cases which is needed to do the store_hash=false change in the compiler # source code. # # df5f0517b33b5f7bc2a508cf6a0ee62246f02d21 preserves result type # information through the address-of operator. # # (@motiejus) llvm17 STEP37=6bd54a1d3ebd8d997158c57057ba742824cf7e0c STEP37_=0.11.0-587-g6bd54a1d3e step37() { rm -fr "../zig-$STEP37_" git archive --prefix=zig-$STEP37_/ $STEP37 | tar -C .. -x { pushd "../zig-$STEP37_" ../zig-$STEP36_/build/zig2 build --zig-lib-dir lib update-zig1 popd } } # commit 21780899eb17a0cb795ff40e5fae6556c38ea13e # Author: Andrew Kelley # Date: 2023-09-27T21:21:59+03:00 # # compiler: don't use `@abs` builtin yet # # This commit can be used to rebuild zig1.wasm # STEP38=21780899eb17a0cb795ff40e5fae6556c38ea13e STEP38_=0.11.0-631-g21780899eb step38() { rm -fr "../zig-$STEP38_" git archive --prefix=zig-$STEP38_/ $STEP38 | tar -C .. -x { pushd "../zig-$STEP38_" cp ../zig-$STEP37_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 17 popd } } # commit 9763573ebb4f05eaa1c0bd5598f8dd6aee20ae9c # Author: Andrew Kelley # Date: 2023-09-27T21:28:47+03:00 # # update zig1.wasm # # Needed because the compiler used the now removed `@fabs` builtin and # instead depends on the new `@abs` builtin. # STEP39=9763573ebb4f05eaa1c0bd5598f8dd6aee20ae9c STEP39_=0.11.0-638-g9763573ebb step39() { rm -fr "../zig-$STEP39_" git archive --prefix=zig-$STEP39_/ $STEP39 | tar -C .. -x { pushd "../zig-$STEP39_" ../zig-$STEP38_/build/zig2 build --zig-lib-dir lib update-zig1 halfbuild 17 popd } } # commit 63bd2bff12992aef0ce23ae4b344e9cb5d65f05d # Author: Veikka Tuominen # Date: 2023-10-01T13:16:02+03:00 # # Sema: add `@errorCast` which works for both error sets and error unions # STEP40=63bd2bff12992aef0ce23ae4b344e9cb5d65f05d STEP40_=0.11.0-702-g63bd2bff12 step40() { rm -fr "../zig-$STEP40_" git archive --prefix=zig-$STEP40_/ $STEP40 | tar -C .. -x { pushd "../zig-$STEP40_" ../zig-$STEP39_/build/zig2 build update-zig1 popd } } # commit 9a09651019b24a32945f73dd7a69562f2cf31581 # Author: Andrew Kelley # Date: 2023-10-04T00:58:13+03:00 # # update zig1.wasm # # Notably, this contains bug fixes related to `@errorCast` which are # required by the changes to `std.io.Reader` in this branch, and the # compiler source code has a dependency on `std.io.Reader`. STEP41=9a09651019b24a32945f73dd7a69562f2cf31581 STEP41_=0.11.0-761-g9a09651019 step41() { rm -fr "../zig-$STEP41_" git archive --prefix=zig-$STEP41_/ $STEP41 | tar -C .. -x { pushd "../zig-$STEP41_" cp ../zig-$STEP40_/stage1/zig1.wasm stage1/zig1.wasm halfbuild 17 popd } } if [[ "${BASH_SOURCE[0]}" == "${0}" ]]; then set -xeuo pipefail step=${1:-step00} step=${step#step} step=${step#0} if [[ "$step" -le 0 ]]; then step00; fi if [[ "$step" -le 1 ]]; then step01; fi if [[ "$step" -le 2 ]]; then step02; fi if [[ "$step" -le 3 ]]; then step03; fi if [[ "$step" -le 4 ]]; then step04; fi if [[ "$step" -le 5 ]]; then step05; fi if [[ "$step" -le 6 ]]; then step06; fi if [[ "$step" -le 7 ]]; then step07; fi if [[ "$step" -le 8 ]]; then step08; fi if [[ "$step" -le 9 ]]; then step09; fi if [[ "$step" -le 10 ]]; then step10; fi if [[ "$step" -le 11 ]]; then step11; fi if [[ "$step" -le 12 ]]; then step12; fi if [[ "$step" -le 13 ]]; then step13; fi if [[ "$step" -le 14 ]]; then step14; fi if [[ "$step" -le 15 ]]; then step15; fi if [[ "$step" -le 16 ]]; then step16; fi if [[ "$step" -le 17 ]]; then step17; fi if [[ "$step" -le 18 ]]; then step18; fi if [[ "$step" -le 19 ]]; then step19; fi if [[ "$step" -le 20 ]]; then step20; fi if [[ "$step" -le 21 ]]; then step21; fi if [[ "$step" -le 22 ]]; then step22; fi if [[ "$step" -le 23 ]]; then step23; fi if [[ "$step" -le 24 ]]; then step24; fi if [[ "$step" -le 25 ]]; then step25; fi if [[ "$step" -le 26 ]]; then step26; fi if [[ "$step" -le 27 ]]; then step27; fi if [[ "$step" -le 28 ]]; then step28; fi if [[ "$step" -le 29 ]]; then step29; fi if [[ "$step" -le 30 ]]; then step30; fi if [[ "$step" -le 31 ]]; then step31; fi if [[ "$step" -le 32 ]]; then step32; fi if [[ "$step" -le 33 ]]; then step33; fi if [[ "$step" -le 34 ]]; then step34; fi if [[ "$step" -le 35 ]]; then step35; fi if [[ "$step" -le 36 ]]; then step36; fi if [[ "$step" -le 37 ]]; then step37; fi if [[ "$step" -le 38 ]]; then step38; fi if [[ "$step" -le 39 ]]; then step39; fi if [[ "$step" -le 40 ]]; then step40; fi if [[ "$step" -le 41 ]]; then step41; fi fi