1CC ?= gcc 2CFLAGS ?= -Wall -O2 3LDFLAGS ?= 4TERMLIB = -lncurses 5srcdir ?= . 6 7all: lesstest lt_screen 8 9LESSTEST_SRC = display.c env.c lesstest.c parse.c pipeline.c log.c run.c term.c wchar.c 10LESSTEST_OBJ = $(patsubst %.c,%.o,$(LESSTEST_SRC)) 11 12lesstest: $(LESSTEST_OBJ) 13 $(CC) $(CFLAGS) $(LDFLAGS) -o lesstest $(LESSTEST_OBJ) $(TERMLIB) 14 15LT_SCREEN_SRC = lt_screen.c unicode.c wchar.c 16LT_SCREEN_OBJ = $(patsubst %.c,%.o,$(LT_SCREEN_SRC)) 17lt_screen: $(LT_SCREEN_OBJ) 18 $(CC) $(CFLAGS) $(LDFLAGS) -o lt_screen $(LT_SCREEN_OBJ) 19 20HDR = lesstest.h lt_types.h wchar.h 21*.o: $(HDR) 22 23echo_distfiles: 24 @echo $(patsubst %,$(srcdir)/%,$(LESSTEST_SRC) $(LT_SCREEN_SRC) $(HDR) lt/*.lt runtest maketest Makefile) 25 26clean: 27 rm -f lesstest lt_screen *.o 28