Skip to content

Commit

Permalink
No static linking on mac? Fun!
Browse files Browse the repository at this point in the history
  • Loading branch information
piepie62 committed Apr 22, 2020
1 parent 20f4561 commit ed12be7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,18 @@ BUILD_OFILES := $(addprefix $(BUILD)/, $(BUILD_OFILES))
DEPSFILES := $(BUILD_OFILES:.o=.d)

LD := $(if $(CPPFILES),$(CXX),$(CC))
LDFLAGS := -g -static -Wl,--gc-sections -lbz2
LDFLAGS := -g -Wl,--gc-sections -lbz2

ifeq ($(OS),Windows_NT)
EXEC_NAME := gallerypack.exe
else
LDFLAGS += -lstdc++fs
endif

ifneq ($(OS),Darwin)
LDFLAGS += -static
endif

.PHONY: all clean

all: $(EXEC_NAME)
Expand Down

0 comments on commit ed12be7

Please sign in to comment.