dht22, main, makefile

This commit is contained in:
2017-01-22 18:54:30 +01:00
parent 8502efa1d9
commit 2167638d2b
4 changed files with 160 additions and 0 deletions

25
makefile Normal file
View File

@@ -0,0 +1,25 @@
#Infos: http://www.ijon.de/comp/tutorials/makefile.html
VERSION = 1.0
CC = /usr/bin/gcc
CFLAGS = -Wall -g -D_REENTRANT -DVERSION=\"$(VERSION)\"
#LDFLAGS = -lm -lpthread `gtk-config --cflags` `gtk-config --libs` -lgthread
LDFLAGS = -lwiringPi
OBJ = main.o dht22.o
dht22: $(OBJ)
$(CC) $(CFLAGS) -o dht22 $(OBJ) $(LDFLAGS)
%.o: %.c
$(CC) $(CFLAGS) -c $<
.PHONY: clean
clean:
rm -r *.o
install:
sudo cp -r lcdclock /usr/local/bin
sudo cp -r playsong.sh /usr/local/bin
sudo cp -r settings.cfg /usr/local/bin