wangzhengquan
2020-07-16 3feff4ae44fd74c32158ed5f505e063b154c4d76
Make.defines.linux
@@ -2,19 +2,32 @@
# Definitions required in all program directories to compile and link
# C programs using gcc.
DEBUG=y
CC = g++
COMPILE.c = $(CC) $(CFLAGS) $(CPPFLAGS) -c
LINK.c = $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS)
LDFLAGS=
LDDIR += -L$(ROOT)/lib
LDLIBS += $(LDDIR) $(EXTRALIBS)
INCLUDE += -I. -I./include -I$(ROOT)/include -I$(ROOT)/include/usgcommon
ifeq ($(DEBUG),y)
  DEBFLAGS = -O -g # "-O" is needed to expand inlines
else
  DEBFLAGS = -O2
endif
CFLAGS = $(INCLUDE) -g -std=c++11 -mcx16 -Wall  -DLINUX -D_GNU_SOURCE $(EXTRA)
CFLAGS += $(INCLUDE)  $(DEBFLAGS) -mcx16 -std=c++11 -Wall -DLINUX -D_GNU_SOURCE $(EXTRA)
RANLIB=echo
AR=ar
AWK=awk
#LIBCOMMON=$(ROOT)/common/libusgcommon.a
# Common temp files to delete from each directory.
TEMPFILES=core core.* *.o temp.* *.out *.a *.so
%:   %.c
   $(CC) $(CFLAGS) $^ -o $@ $(LDFLAGS) $(LDLIBS)