Skip to content

Commit

Permalink
Build variant fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
ralight committed Oct 13, 2020
1 parent d70ffd4 commit 24a9c7d
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 3 deletions.
6 changes: 6 additions & 0 deletions apps/mosquitto_passwd/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ OBJS= mosquitto_passwd.o \
misc_mosq.o \
password_mosq.o

ifeq ($(WITH_TLS),yes)
all: mosquitto_passwd
else
all:
endif

mosquitto_passwd : ${OBJS}
${CROSS_COMPILE}${CC} ${APP_LDFLAGS} $^ -o $@ $(PASSWD_LDADD)

Expand Down
1 change: 1 addition & 0 deletions buildtest.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
build_variants = [
'WITH_ADNS',
'WITH_BRIDGE',
'WITH_CJSON',
'WITH_DOCS',
'WITH_EC',
'WITH_EPOLL',
Expand Down
8 changes: 5 additions & 3 deletions config.mk
Original file line number Diff line number Diff line change
Expand Up @@ -217,12 +217,13 @@ ifeq ($(WITH_WRAP),yes)
endif

ifeq ($(WITH_TLS),yes)
BROKER_LDADD:=$(BROKER_LDADD) -lssl -lcrypto
LIB_LIBADD:=$(LIB_LIBADD) -lssl -lcrypto
APP_CPPFLAGS:=$(APP_CPPFLAGS) -DWITH_TLS
BROKER_CPPFLAGS:=$(BROKER_CPPFLAGS) -DWITH_TLS
BROKER_LDADD:=$(BROKER_LDADD) -lssl -lcrypto
CLIENT_CPPFLAGS:=$(CLIENT_CPPFLAGS) -DWITH_TLS
LIB_CPPFLAGS:=$(LIB_CPPFLAGS) -DWITH_TLS
LIB_LIBADD:=$(LIB_LIBADD) -lssl -lcrypto
PASSWD_LDADD:=$(PASSWD_LDADD) -lcrypto
CLIENT_CPPFLAGS:=$(CLIENT_CPPFLAGS) -DWITH_TLS
STATIC_LIB_DEPS:=$(STATIC_LIB_DEPS) -lssl -lcrypto

ifeq ($(WITH_TLS_PSK),yes)
Expand Down Expand Up @@ -347,6 +348,7 @@ endif
ifeq ($(WITH_CJSON),yes)
CLIENT_CFLAGS:=$(CLIENT_CFLAGS) -DWITH_CJSON -I/usr/include/cjson -I/usr/local/include/cjson
CLIENT_LDADD:=$(CLIENT_LDADD) -lcjson
CLIENT_STATIC_LDADD:=$(CLIENT_STATIC_LDADD) -lcjson
endif

BROKER_LDADD:=${BROKER_LDADD} ${LDADD}
Expand Down
2 changes: 2 additions & 0 deletions src/password_mosq.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ and the Eclipse Distribution License is available at

#include "misc_mosq.h"

#ifdef WITH_TLS
int base64_encode(unsigned char *in, unsigned int in_len, char **encoded)
{
BIO *bmem, *b64;
Expand Down Expand Up @@ -178,6 +179,7 @@ int pw__hash(const char *password, struct mosquitto_pw *pw, bool new_salt)

return MOSQ_ERR_SUCCESS;
}
#endif

int pw__memcmp_const(const void *a, const void *b, size_t len)
{
Expand Down

0 comments on commit 24a9c7d

Please sign in to comment.