summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorLars-Dominik Braun <lars@6xq.net>2011-09-22 10:39:44 +0200
committerLars-Dominik Braun <lars@6xq.net>2011-11-09 20:10:16 +0100
commit50a5cac2445bc0c199958ac04d5127e4be09fb1e (patch)
tree84e32e498be8f6de52569aa0dda8d64b04da535c /Makefile
parent1679beb2887f04c322acc06593a36ce80b0129ea (diff)
downloadpianobar-windows-50a5cac2445bc0c199958ac04d5127e4be09fb1e.tar.gz
pianobar-windows-50a5cac2445bc0c199958ac04d5127e4be09fb1e.tar.bz2
pianobar-windows-50a5cac2445bc0c199958ac04d5127e4be09fb1e.zip
waitress: Initial TLS implementation (using gnutls)
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile16
1 files changed, 12 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index 2274644..2546ae9 100644
--- a/Makefile
+++ b/Makefile
@@ -85,17 +85,25 @@ else
LIBMAD_LDFLAGS=-lmad
endif
+ifeq (${DISABLE_GNUTLS}, 1)
+ LIBGNUTLS_CFLAGS=
+ LIBGNUTLS_LDFLAGS=
+else
+ LIBGNUTLS_CFLAGS=-DENABLE_TLS
+ LIBGNUTLS_LDFLAGS=-lgnutls
+endif
+
# build pianobar
ifeq (${DYNLINK},1)
pianobar: ${PIANOBAR_OBJ} ${PIANOBAR_HDR} libpiano.so.0
${CC} -o $@ ${PIANOBAR_OBJ} ${LDFLAGS} -lao -lpthread -lm -L. -lpiano \
- ${LIBFAAD_LDFLAGS} ${LIBMAD_LDFLAGS}
+ ${LIBFAAD_LDFLAGS} ${LIBMAD_LDFLAGS} ${LIBGNUTLS_LDFLAGS}
else
pianobar: ${PIANOBAR_OBJ} ${PIANOBAR_HDR} ${LIBPIANO_OBJ} ${LIBWAITRESS_OBJ} \
${LIBWAITRESS_HDR} ${LIBEZXML_OBJ} ${LIBEZXML_HDR}
${CC} ${CFLAGS} ${LDFLAGS} ${PIANOBAR_OBJ} ${LIBPIANO_OBJ} \
${LIBWAITRESS_OBJ} ${LIBEZXML_OBJ} -lao -lpthread -lm \
- ${LIBFAAD_LDFLAGS} ${LIBMAD_LDFLAGS} -o $@
+ ${LIBFAAD_LDFLAGS} ${LIBMAD_LDFLAGS} ${LIBGNUTLS_LDFLAGS} -o $@
endif
# build shared and static libpiano
@@ -112,7 +120,7 @@ libpiano.so.0: ${LIBPIANO_RELOBJ} ${LIBPIANO_HDR} ${LIBWAITRESS_RELOBJ} \
%.o: %.c
${CC} ${CFLAGS} -I ${LIBPIANO_INCLUDE} -I ${LIBWAITRESS_INCLUDE} \
-I ${LIBEZXML_INCLUDE} ${LIBFAAD_CFLAGS} \
- ${LIBMAD_CFLAGS} -c -o $@ $<
+ ${LIBMAD_CFLAGS} ${LIBGNUTLS_CFLAGS} -c -o $@ $<
# create position independent code (for shared libraries)
%.lo: %.c
@@ -131,7 +139,7 @@ debug: CFLAGS=-Wall -pedantic -ggdb
waitress-test: CFLAGS+= -DTEST
waitress-test: ${LIBWAITRESS_OBJ}
- ${CC} ${LDFLAGS} ${LIBWAITRESS_OBJ} -o waitress-test
+ ${CC} ${LDFLAGS} ${LIBWAITRESS_OBJ} ${LIBGNUTLS_LDFLAGS} -o waitress-test
test: waitress-test
./waitress-test