Skip to content

Commit e4b1e26

Browse files
asg017claude
andcommitted
Fix macOS fuzz: use Xcode clang instead of Homebrew LLVM
Homebrew LLVM 18's ASAN/libFuzzer runtimes contain weak-def symbols for typed allocation operators (__ZnwmSt19__type_descriptor_t) that don't exist in macOS 14's system libc++. Since the symbol is embedded in the pre-built runtime dylibs (not our code), link-time flags cannot fix it. Switch to Apple's Xcode clang which ships its own libFuzzer and ASAN runtime built against the system libc++ — no ABI mismatch possible. No Homebrew LLVM install needed. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent b93a669 commit e4b1e26

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

.github/workflows/fuzz.yaml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -63,20 +63,17 @@ jobs:
6363
runs-on: macos-14
6464
steps:
6565
- uses: actions/checkout@v4
66-
- name: Install LLVM 18
67-
run: brew install llvm@18
66+
# Use Apple's Xcode clang (avoids Homebrew LLVM libc++ ABI issues
67+
# with __ZnwmSt19__type_descriptor_t on macOS 14).
6868
- run: ./scripts/vendor.sh
6969
- name: Generate sqlite-vec.h
7070
run: make sqlite-vec.h
7171
- name: Build fuzz targets
7272
run: |
73-
LLVM=/opt/homebrew/opt/llvm@18
7473
make -C tests/fuzz all \
75-
FUZZ_CC=$LLVM/bin/clang \
76-
FUZZ_LDFLAGS="-Wl,-ld_classic -nostdlib++ -L$LLVM/lib/c++ -lc++ -Wl,-rpath,$LLVM/lib/c++"
74+
FUZZ_CC=$(xcrun -f clang) \
75+
FUZZ_LDFLAGS=""
7776
- name: Run fuzz targets
78-
env:
79-
DYLD_LIBRARY_PATH: "/opt/homebrew/opt/llvm@18/lib/c++:${{ env.DYLD_LIBRARY_PATH }}"
8077
run: |
8178
DURATION=${{ github.event.inputs.duration || '60' }}
8279
EXIT_CODE=0

0 commit comments

Comments
 (0)