aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorArslaan Pathan <[email protected]>2025-06-11 18:50:36 +1200
committerArslaan Pathan <[email protected]>2025-06-11 18:50:36 +1200
commit5dfe69e4580073c9bdeaed605a46cf0ec3e24ad2 (patch)
treec3f806aa2daa6504fbffbad84b867c3c56454daa /Makefile
parent1e140985c594e21c52a11567e616613385f22b15 (diff)
downloadshowdownofthesticks-5dfe69e4580073c9bdeaed605a46cf0ec3e24ad2.tar.xz
showdownofthesticks-5dfe69e4580073c9bdeaed605a46cf0ec3e24ad2.zip
Add support for bundling SDL2 in Mac binaries
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 4 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 1642d3f..05fdbd8 100644
--- a/Makefile
+++ b/Makefile
@@ -35,6 +35,10 @@ $(TARGET): $(OBJ_CPP) $(LUA_OBJ)
ifeq ($(MAKE_APP),true)
mkdir -p $(dir $(INFO_PLIST))
cp Info.plist $(INFO_PLIST)
+ mkdir -p $(TARGET_DIR)
+ cp /opt/homebrew/opt/sdl2/lib/libSDL2-2.0.0.dylib $(TARGET_DIR)/libSDL2.dylib
+ install_name_tool -change /opt/homebrew/opt/sdl2/lib/libSDL2-2.0.0.dylib @executable_path/libSDL2.dylib $(TARGET)
+ otool -l $(TARGET)
endif
build/main.o: src/main.cpp