mirror of
https://github.com/thepigeongenerator/mcaselector-lite
synced 2026-02-08 07:33:35 +01:00
fix: GNU Make predefines variables, and ?= will not behave as expected.
This commit is contained in:
12
Makefile
12
Makefile
@@ -9,13 +9,11 @@ SHELL = /bin/sh
|
|||||||
|
|
||||||
NAME = mcaselector-lite
|
NAME = mcaselector-lite
|
||||||
|
|
||||||
CC ?= cc
|
|
||||||
RM ?= rm -vf
|
|
||||||
CMAKE ?= cmake -G 'Unix Makefiles'
|
CMAKE ?= cmake -G 'Unix Makefiles'
|
||||||
|
|
||||||
CPPFLAGS ?= -DNDEBUG
|
CPPFLAGS = -DNDEBUG
|
||||||
CFLAGS ?= -O2
|
CFLAGS = -O2
|
||||||
LDFLAGS ?= -flto
|
LDFLAGS = -flto
|
||||||
|
|
||||||
CPPFLAGS += -DGLFW_INCLUDE_NONE
|
CPPFLAGS += -DGLFW_INCLUDE_NONE
|
||||||
CPPFLAGS += -Iinclude -Ilib/glad/include -Ilib/glfw/include -Ilib/libarchive/libarchive
|
CPPFLAGS += -Iinclude -Ilib/glad/include -Ilib/glfw/include -Ilib/libarchive/libarchive
|
||||||
@@ -53,8 +51,8 @@ TOBJ := $(TSRC:%.c=obj/%.o)
|
|||||||
all: bin/$(NAME)
|
all: bin/$(NAME)
|
||||||
libs: lib/obj/glfw/ lib/obj/libarchive/
|
libs: lib/obj/glfw/ lib/obj/libarchive/
|
||||||
check: bin/TEST_$(NAME); ./$<
|
check: bin/TEST_$(NAME); ./$<
|
||||||
clean:; @-$(RM) -r bin/ obj/
|
clean:; @-$(RM) -rv bin/ obj/
|
||||||
clean-libs:; @-$(RM) -r lib/obj/
|
clean-libs:; @-$(RM) -rv lib/obj/
|
||||||
|
|
||||||
.PHONY:
|
.PHONY:
|
||||||
install: all
|
install: all
|
||||||
|
|||||||
Reference in New Issue
Block a user