# Change CONFIG to the .mk file that matches your system

CONFIG = system.mk

# Do Not Change anything below this line. It should be setup in config

include ../$(CONFIG)

# this is for revised ntserv/struct.h

#OPT = -g

CFLAGS = $(OPT) $(EXTRAINCS) $(DIRS) $(FLAGS)

LIBS = $(EXTRALIBS)

TOOLDIR= $(LIBDIR)/tools

GETPATH = getpath.o data.o

LINTFLAGS = -habxc $(EXTRAINCS) $(FLAGS)

#	Common Objects

C_OBJS = data.o  \
	openmem.o  \
	smessage.o \
        strdup.o \
        roboshar.o \
        slotmaint.o

#	Sequencer Objects

S_OBJS = sequencer.o  commands_sequencer.o $(C_OBJS)

SRCS = rmove.c getpath.c \
	data.c  detonate.c  enter.c  getship.c  interface.c \
	orbit.c  phaser.c  sintab.c openmem.c sysdefaults.c torp.c \
	util.c $(RANDOMC) commands.c smessage.c basep.c wander2.c \
	inl.c inlcomm.c slotmaint.c

EXECS =	sequencer 

all: $(PMAKE) $(EXECS)

sequencer: $(PMAKE) $(S_OBJS)
	$(CC) $(CFLAGS)  -o sequencer $(S_OBJS) $(EXTRALIBS)

commands_sequencer.o: $(PMAKE) commands.c
	$(CC) $(CFLAGS) $(DEP) -DSEQUENCER -c commands.c -o commands_sequencer.o

clean:; rm -f *.o *.ln

reallyclean:; rm -f $(EXECS) *~ #*#


install: $(EXECS) 
	$(INSTALL) $(INSTALLOPTS) sequencer $(LIBDIR)/sequencer

lint: $(SRCS)
	lint $(LINTFLAGS) -u $?
	touch lint

rmdependencies:
	makedepend

depend:
	makedepend $(CFLAGS) -f Makefile $(SRCS)
#####
# DO NOT DELETE THIS LINE -- make depend depends on it.
