46 lines
1.7 KiB
Makefile
46 lines
1.7 KiB
Makefile
cc = gcc
|
|
# CFLAGS = -Wall -g
|
|
MQTT_CFLAGS = -lmosquitto -lpthread -ldl
|
|
MQTT_CFLAGS += -I./includes
|
|
MQTT_CFLAGS += -L./mqtt_libs
|
|
|
|
SQLITE3_CFLAGS = -lpthread -ldl
|
|
SQLITE3_CFLAGS += -I./includes
|
|
|
|
CJSON_CFLAGS = -lcjson
|
|
|
|
|
|
all:
|
|
$(cc) sqlite3.c mqtt_sub_ctos.c -o mqtt_sub_ctos.cgi $(MQTT_CFLAGS) $(CJSON_CFLAGS) $(SQLITE3_CFLAGS)
|
|
$(cc) mqtt_pub_stoc.c -o mqtt_pub_stoc.cgi $(MQTT_CFLAGS)
|
|
$(cc) sqlite3.c sqlite_cgi_base.c -o sqlite_cgi_base.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
$(cc) sqlite3.c sqlite_cgi_insert_base.c -o sqlite_cgi_insert_base.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
$(cc) sqlite3.c green_house_info_show.c -o green_house_info_show.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
$(cc) sqlite3.c record_of_operations_history.c -o record_of_operations_history.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
|
|
record_of_operations_history:
|
|
$(cc) sqlite3.c record_of_operations_history.c -o record_of_operations_history.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
|
|
|
|
green_house_info_show:
|
|
$(cc) sqlite3.c green_house_info_show.c -o green_house_info_show.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
|
|
sqlite_cgi_base:
|
|
$(cc) sqlite3.c sqlite_cgi_base.c -o sqlite_cgi_base.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
|
|
sqlite_cgi_insert_base:
|
|
$(cc) sqlite3.c sqlite_cgi_insert_base.c -o sqlite_cgi_insert_base.cgi $(SQLITE3_CFLAGS) $(CJSON_CFLAGS)
|
|
|
|
mqtt_sub_ctos:
|
|
$(cc) sqlite3.c mqtt_sub_ctos.c -o mqtt_sub_ctos.cgi $(MQTT_CFLAGS) $(CJSON_CFLAGS) $(SQLITE3_CFLAGS)
|
|
|
|
mqtt_pub_stoc:
|
|
$(cc) mqtt_pub_stoc.c -o mqtt_pub_stoc.cgi $(MQTT_CFLAGS)
|
|
|
|
|
|
mqtt:
|
|
$(cc) sqlite3.c mqtt_sub_ctos.c -o mqtt_sub_ctos.cgi $(MQTT_CFLAGS) $(CJSON_CFLAGS) $(SQLITE3_CFLAGS)
|
|
$(cc) mqtt_pub_stoc.c -o mqtt_pub_stoc.cgi $(MQTT_CFLAGS)
|
|
|
|
clean:
|
|
rm -rf *.cgi
|