Fix Apple clang PCH compile error with -o flag (#7251) (#7327)

Apple clang rejects `-o` when a precompiled header (.gch) is involved,
reporting "cannot specify -o when generating multiple output files".
Remove the unnecessary `-o $@` from the two PCH build rules; the
`%.o: %.cpp` pattern already implies the correct output name.
This commit is contained in:
Eunseo Song 2026-03-27 00:52:21 +09:00 committed by GitHub
parent 3ddf7ad6ec
commit fbc3b3618d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 2 deletions

View File

@ -60,6 +60,7 @@ Driss Hafdi
Edgar E. Iglesias
Eric Müller
Eric Rippey
Eunseo Song
Ethan Sifferman
Eyck Jentzsch
Fabian Keßler-Schulz

View File

@ -280,10 +280,10 @@ ifneq ($(VM_DEFAULT_RULES),0)
$(OBJCACHE) $(CXX) $(OPT_FAST) $(CXXFLAGS) $(CPPFLAGS) -c -o $@ $<
$(VK_OBJS_FAST): %.o: %.cpp $(VK_PCH_H).fast.gch
$(OBJCACHE) $(CXX) $(OPT_FAST) $(CXXFLAGS) $(CPPFLAGS) $(VK_PCH_I_FAST) -c -o $@ $<
$(OBJCACHE) $(CXX) $(OPT_FAST) $(CXXFLAGS) $(CPPFLAGS) $(VK_PCH_I_FAST) -c $<
$(VK_OBJS_SLOW): %.o: %.cpp $(VK_PCH_H).slow.gch
$(OBJCACHE) $(CXX) $(OPT_SLOW) $(CXXFLAGS) $(CPPFLAGS) $(VK_PCH_I_SLOW) -c -o $@ $<
$(OBJCACHE) $(CXX) $(OPT_SLOW) $(CXXFLAGS) $(CPPFLAGS) $(VK_PCH_I_SLOW) -c $<
$(VK_GLOBAL_OBJS): %.o: %.cpp
$(OBJCACHE) $(CXX) $(OPT_GLOBAL) $(CXXFLAGS) $(CPPFLAGS) -c -o $@ $<