Closed junjihashimoto closed 5 months ago
Thanks for filing the inaugural issue @junjihashimoto ! Can you try again with HEAD and make clean
before make
?
The dawn build is more brittle and opaque than I would like. Going through the WebGPU-distribution intermediary isn't ideal but I haven't found a better solution + may pin to specific commits in the near future.
I tried the HEAD (2223ea40d635d9d6872840ab6fb0e8076191b82b). But the error remains. I can build the latest branch of https://dawn.googlesource.com/dawn on macos. For now, I'll try gpu.cpp with the latest dawn.
It works with the latest dawn, but it needs to link many libraries as follows:
$ clang++ -o main ./CMakeFiles/run_demo.dir/run.cpp.o ../dawn/out/Debug/src/tint/libtint_*.a ../dawn/out/Debug//src/dawn/platform/libdawn_platform.a ../dawn/out/Debug//src/dawn/common/libdawn_common.a ../dawn/out/Debug/src/dawn/native/libdawn_native.a ../dawn/out/Debug/src/dawn/native/libwebgpu_dawn.a ../dawn/out/Debug//third_party/abseil/absl/*/libabsl_*.a -framework QuartzCore -framework Metal -framework IOSurface -framework CoreFoundation -framework Security -framework IOKit -framework AppKit -lobjc
Strange for me I don't need to specify link targets manually like that, make clean
then make
and Fetchcontent + cmake seem to be sufficient to just work. I don't even have protobuf installed via homebrew.
(base) austinhuang@Austins-MacBook-Pro gpu.cpp % brew info protobuf
==> protobuf: stable 26.1 (bottled)
Protocol buffers (Google's data interchange format)
https://protobuf.dev/
Not installed
From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/p/protobuf.rb
License: BSD-3-Clause
==> Dependencies
Build: cmake ✘
Required: abseil ✘, jsoncpp ✘
==> Analytics
install: 56,407 (30 days), 164,486 (90 days), 694,039 (365 days)
install-on-request: 25,188 (30 days), 78,064 (90 days), 324,149 (365 days)
build-error: 216 (30 days)
(base) austinhuang@Austins-MacBook-Pro gpu.cpp % uname -a
Darwin Austins-MacBook-Pro.local 21.4.0 Darwin Kernel Version 21.4.0: Mon Feb 21 20:35:58 PST 2022; root:
xnu-8020.101.4~2/RELEASE_ARM64_T6000 arm64
Maybe some aspects of developer tooling broke between Monterey and Ventura? Wouldn't be the first time :/
I'll try upgrading and see if I can replicate it.
The build was not working because I was running cmake myself.
make demo
works.
Compilation error occurs when building libprotobuf-mutator on macos.