#
#
# Flags that might be overriden by top makefile
#
INSTALLROOT = /usr/local


CC=gcc
CCFLAG=-s -O -Wall
LDFLAG=-s -O -L/usr/X11R6/lib

SYSLIB=-lXpm -lX11 -lm
XINCLUDE=-I/usr/X11R6/include/X11

SHELL=/bin/sh

#
# Flags the compiler will see
#

CFLAGS=$(CCFLAG) $(XINCLUDE)
LDFLAGS = $(LDFLAG) 

# if your libforms.so is standard use
LIBS=-lforms $(SYSLIB)


# if you want to have a static binary
# LIBS=/usr/X11R6/lib/libforms.a $(SYSLIB)


all: l3t 


l3t:	lab-timer.o layout.o  msg_window.o help_window.o tooltip.o util.o get_cmdl.o \
		help_window.h msg_window.h layout.h my_config.h util.h lab-timer.h helptext.h
	-$(CC) $(LDFLAGS)  -o $@ lab-timer.o tooltip.o util.o layout.o  msg_window.o get_cmdl.o \
		help_window.o $(LIBS)


install:
	install -m 755 l3t $(INSTALLROOT)/bin
	install -m 644 l3t.1 $(INSTALLROOT)/man/man1


clean:
	-rm -f  *.o core a.out *~ l3t

