Add testing target for compiling test client fixes.

This commit is contained in:
Roger A. Light 2020-01-02 21:40:03 +00:00
parent d452ea138b
commit 6aa9b91fff
2 changed files with 11 additions and 0 deletions

2
.gitignore vendored
View File

@ -20,6 +20,8 @@ build/
client/mosquitto_pub
client/mosquitto_rr
client/mosquitto_sub
client/testing
client/testing.c
cov-int/

View File

@ -59,6 +59,15 @@ client_shared.o : client_shared.c client_shared.h
client_props.o : client_props.c client_shared.h
${CROSS_COMPILE}${CC} $(CLIENT_CPPFLAGS) $(CLIENT_CFLAGS) -c $< -o $@
# The "testing" target is intended to make it easy to compile a quick client
# for testing purposes. testing.c should not be committed as a file.
testing : testing.o
${CROSS_COMPILE}${CC} $(CLIENT_LDFLAGS) $^ -o $@ $(CLIENT_LDADD) $(CLIENT_LDFLAGS)
testing.o : testing.c
${CROSS_COMPILE}${CC} $(CLIENT_CPPFLAGS) $(CLIENT_CFLAGS) -c $< -o $@
../lib/libmosquitto.so.${SOVERSION} :
$(MAKE) -C ../lib