cleanup Makefile
This commit is contained in:
parent
71b0f8c686
commit
d415e5cbaf
13
Makefile
13
Makefile
|
@ -1,16 +1,11 @@
|
||||||
CC=gcc
|
CC=gcc
|
||||||
CFLAGS=-Wall -O3
|
CFLAGS=-Wall -O3
|
||||||
UNAME_S := $(shell uname -s)
|
PICRIN_LIB=libpicrin.so
|
||||||
SO_PREFIX=lib
|
|
||||||
SO_EXT=.so
|
|
||||||
|
|
||||||
ifeq ($(findstring CYGWIN,$(UNAME_S)), CYGWIN)
|
ifeq ($(findstring CYGWIN,$(shell uname -s)), CYGWIN)
|
||||||
SO_PREFIX=cyg
|
PICRIN_LIB =cygpicrin.dll
|
||||||
SO_EXT=.dll
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
PICRIN_LIB=$(SO_PREFIX)picrin$(SO_EXT)
|
|
||||||
|
|
||||||
all: build-debug run
|
all: build-debug run
|
||||||
|
|
||||||
release: CFLAGS += -DDEBUG=0
|
release: CFLAGS += -DDEBUG=0
|
||||||
|
@ -33,7 +28,7 @@ build-lib:
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f src/y.tab.c src/y.tab.h src/lex.yy.c
|
rm -f src/y.tab.c src/y.tab.h src/lex.yy.c
|
||||||
rm -f lib/$(PICRIN_LIB)
|
rm -f lib/$(PICRIN_LIB) bin/$(PICRIN_LIB)
|
||||||
rm -f bin/picrin
|
rm -f bin/picrin
|
||||||
|
|
||||||
run:
|
run:
|
||||||
|
|
Loading…
Reference in New Issue