home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
linuxmafia.com 2016
/
linuxmafia.com.tar
/
linuxmafia.com
/
pub
/
palmos
/
bart-1.3b2.tar.gz
/
bart-1.3b2.tar
/
bart-1.3b2
/
Makefile
< prev
next >
Wrap
Makefile
|
2000-03-12
|
3KB
|
107 lines
## Makefile for BART Scheduler
TARGET = bart
APPNAME = "BART Scheduler"
APPID = "BART"
PDB_FILE = $(TARGET)data.pdb
# grab version string from the .rcp file
VERSION = $(shell perl -lne 'print $$1 if /^\s*VERSION\s+\S+\s+"(.+?)"/' $(TARGET).rcp)
DISTFILES = $(TARGET).prc $(PDB_FILE) README LICENSE TODO
CVS_MODULE = bart
# change . to _ to get CVS version tag
CVS_VERSION = v$(subst .,_,$(VERSION))
OBJS = $(TARGET).o find.o
LIBS =
DEFS =
CC = m68k-palmos-coff-gcc
CFLAGS = $(DEFS) -Wall -g -O2
PILRC = pilrc
OBJRES = m68k-palmos-coff-obj-res
NM = m68k-palmos-coff-nm
BUILDPRC = build-prc
PILOTXFER = pilot-xfer
COPILOTXFER = pilot-xfer -p /dev/copilot
all: $(TARGET).prc
.S.o:
$(CC) $(TARGETFLAGS) -c $<
.c.s:
$(CC) $(CSFLAGS) $<
$(TARGET).c: $(TARGET).h
$(TARGET).h: $(PDB_FILE)
$(PDB_FILE): data/bike-names data/bike-restrictions data/fares data/schedules/weekday data/schedules/saturday data/schedules/sunday data/stations data/transfers
data/make-pdb-file
data/schedules/weekday: data/schedules/raw
data/schedules/extract-sched
data/schedules/saturday: data/schedules/raw
data/schedules/extract-sched
data/schedules/sunday: data/schedules/raw
data/schedules/extract-sched
$(TARGET).prc: code0000.$(TARGET).grc code0001.$(TARGET).grc data0000.$(TARGET).grc pref0000.$(TARGET).grc rloc0000.$(TARGET).grc bin.res
$(BUILDPRC) $(TARGET).prc $(APPNAME) $(APPID) code0001.$(TARGET).grc code0000.$(TARGET).grc data0000.$(TARGET).grc *.bin pref0000.$(TARGET).grc rloc0000.$(TARGET).grc
code0000.$(TARGET).grc: $(TARGET)
$(OBJRES) $(TARGET)
code0001.$(TARGET).grc: code0000.$(TARGET).grc
data0000.$(TARGET).grc: code0000.$(TARGET).grc
pref0000.$(TARGET).grc: code0000.$(TARGET).grc
rloc0000.$(TARGET).grc: code0000.$(TARGET).grc
bin.res: $(TARGET).rcp
$(PILRC) $(TARGET).rcp .
touch bin.res
$(TARGET): $(OBJS)
$(CC) $(CFLAGS) $(OBJS) -o $(TARGET) $(LIBS)
! $(NM) -u $(TARGET) | grep .
send: $(TARGET).prc $(PDB_FILE)
$(PILOTXFER) -i $(TARGET).prc
# $(PILOTXFER) -i $(TARGET).prc $(PDB_FILE)
csend: $(TARGET).prc $(PDB_FILE)
$(COPILOTXFER) -i $(TARGET).prc
# $(COPILOTXFER) -i $(TARGET).prc $(PDB_FILE)
depend:
makedepend -Y -I. *.c
package:
mkdir pkgtemp
cd pkgtemp && cvs -Q export -r $(CVS_VERSION) $(CVS_MODULE)
mv pkgtemp/$(CVS_MODULE) pkgtemp/$(TARGET)-$(VERSION)
cd pkgtemp/$(TARGET)-$(VERSION) && make && make clean
cd pkgtemp && tar cf - $(TARGET)-$(VERSION) | gzip -c > ../../$(TARGET)-$(VERSION).tar.gz
cd pkgtemp && zip -q -r ../../$(TARGET)-$(VERSION).zip $(TARGET)-$(VERSION)
cd pkgtemp/$(TARGET)-$(VERSION) && zip -q ../../../$(TARGET)-ns-$(VERSION).zip $(DISTFILES)
rm -rf pkgtemp
clean:
-rm -f *.[oa] $(TARGET) *.bin bin.res *.grc Makefile.bak
veryclean: clean
-rm -rf $(TARGET).prc $(TARGET).pbm $(PDB_FILE) $(TARGET)data.h pilot.ram pilot.scratch data/schedules/{weekday,saturday,sunday}
# DO NOT DELETE
bart.o: callback.h bartRsc.h bart.h bartdata.h
find.o: callback.h bart.h bartRsc.h