From db77137a23695a420d70d4377ce5a9a5a27cdce5 Mon Sep 17 00:00:00 2001 From: Andrew Belt Date: Tue, 26 Mar 2024 11:54:13 -0400 Subject: [PATCH] Compile .m and .mm files in src/ on Mac. --- Makefile | 2 ++ compile.mk | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/Makefile b/Makefile index f87f881a..dd65371e 100644 --- a/Makefile +++ b/Makefile @@ -43,6 +43,8 @@ ifdef ARCH_MAC SED := sed -i '' TARGET := libRack.dylib + SOURCES += $(wildcard src/*.m src/*/*.m) + SOURCES += $(wildcard src/*.mm src/*/*.mm) SOURCES += dep/osdialog/osdialog_mac.m LDFLAGS += -lpthread -ldl LDFLAGS += -framework SystemConfiguration -framework Cocoa -framework OpenGL -framework IOKit -framework CoreVideo -framework CoreAudio -framework CoreMIDI diff --git a/compile.mk b/compile.mk index 011b4363..bbda7652 100644 --- a/compile.mk +++ b/compile.mk @@ -94,6 +94,10 @@ build/%.m.o: %.m @mkdir -p $(@D) $(CC) $(CFLAGS) -c -o $@ $< +build/%.mm.o: %.mm + @mkdir -p $(@D) + $(CC) $(CXXFLAGS) -c -o $@ $< + build/%.bin.o: % @mkdir -p $(@D) ifdef ARCH_LIN