Makefile 972 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
# NOTE: advised to use lower-case for board name
BOARD = t485-rtm

ELMAIP =
ELMAPWD =
ELMASLOT =

all:
	mkdir -p ubuntu/$(BOARD)/log
	touch ubuntu/$(BOARD)/log/fan-speeds

	cp -r shell/ ubuntu/$(BOARD)/

	mkdir -p	ubuntu/$(BOARD)/pyts/
	cp python/*	ubuntu/$(BOARD)/pyts/

17
	chmod a+x rename; ./rename $(BOARD) $(ELMAIP) $(ELMAPWD) $(ELMASLOT)
18 19 20 21 22 23 24 25 26

	cp ubuntu/$(BOARD)/pyts/pts.py	ubuntu/$(BOARD)/pts
	cp ubuntu/$(BOARD)/pyts/jpts.py	ubuntu/$(BOARD)/jpts
	ln -s pyts/leds.py 		ubuntu/$(BOARD)/test01.py
	ln -s pyts/rs485_pulse_rtm.py	ubuntu/$(BOARD)/test02.py

	mkdir -p ubuntu/$(BOARD)/boot
	mv ubuntu/$(BOARD)/shell/program	ubuntu/$(BOARD)/boot
	mv ubuntu/$(BOARD)/shell/flash	ubuntu/$(BOARD)/boot
27
	wget -P ubuntu/$(BOARD)/boot http://www.ohwr.org/attachments/download/3738/pts.bit
28

29 30 31 32 33
	chmod a+x ubuntu/$(BOARD)/shell/*
	chmod a+x ubuntu/$(BOARD)/boot/*
	chmod a+x ubuntu/$(BOARD)/jpts
	chmod a+x ubuntu/$(BOARD)/pts
	chmod a+w ubuntu/$(BOARD)/*
34 35

clean:
36
	rm -rf ubuntu/$(BOARD)