Commit f4907bc0 authored by valenok's avatar valenok

introdused NO_SSL. Explicitely linking against SSL library.

parent cb71dc4a
...@@ -23,7 +23,8 @@ all: ...@@ -23,7 +23,8 @@ all:
CFLAGS= -W -Wall -std=c99 -pedantic -Os -fomit-frame-pointer $(COPT) CFLAGS= -W -Wall -std=c99 -pedantic -Os -fomit-frame-pointer $(COPT)
MAC_SHARED= -flat_namespace -bundle -undefined suppress MAC_SHARED= -flat_namespace -bundle -undefined suppress
LINFLAGS= -ldl -pthread $(CFLAGS) SSLFLAGS= -lssl -lcrypto
LINFLAGS= -ldl -pthread $(SSLFLAGS) $(CFLAGS)
LIB= _$(PROG).so LIB= _$(PROG).so
linux: linux:
...@@ -32,16 +33,17 @@ linux: ...@@ -32,16 +33,17 @@ linux:
bsd: bsd:
$(CC) $(CFLAGS) mongoose.c -shared -pthread -s -fpic -fPIC -o $(LIB) $(CC) $(CFLAGS) mongoose.c -shared -pthread -s -fpic -fPIC -o $(LIB)
$(CC) $(CFLAGS) mongoose.c main.c -pthread -s -o $(PROG) $(CC) $(CFLAGS) mongoose.c main.c -pthread -s $(SSLFLAGS) -o $(PROG)
mac: mac:
$(CC) $(CFLAGS) $(MAC_SHARED) mongoose.c -pthread -o $(LIB) $(CC) $(CFLAGS) $(MAC_SHARED) mongoose.c -pthread $(SSLFLAGS) -o $(LIB)
$(CC) $(CFLAGS) mongoose.c main.c -pthread -o $(PROG) $(CC) $(CFLAGS) mongoose.c main.c -pthread $(SSLFLAGS) -o $(PROG)
solaris: solaris:
gcc $(CFLAGS) mongoose.c -pthread -lnsl \ gcc $(CFLAGS) mongoose.c -pthread -lnsl \
-lsocket -s -fpic -fPIC -shared -o $(LIB) -lsocket $(SSLFLAGS) -s -fpic -fPIC -shared -o $(LIB)
gcc $(CFLAGS) mongoose.c main.c -pthread -lnsl -lsocket -s -o $(PROG) gcc $(CFLAGS) mongoose.c main.c -pthread -lnsl -lsocket $(SSLFLAGS) \
-s -o $(PROG)
########################################################################## ##########################################################################
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment