News: Portal
Our Simutrans site. You can find everything about Simutrans from here.

How do we use static flag in Makefile?

Started by THLeaderH, March 01, 2017, 01:00:39 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


I found $(STATIC) flag in Makefile.

ifneq ($(STATIC),)
            ifeq ($(shell expr $(STATIC) \>= 1), 1)
              CFLAGS  += -static
              LDFLAGS += -Wl,-Bstatic -lbz2 -Wl,-Bdynamic
# other libs like SDL2 MUST be dynamic!

How do we use this flag when compiling? Editing config.default somehow?


These and other flags can be set in config.default by adding the line "STATIC = 1"