Separated OpenBSD build from the main Makefile into a new one.
diff --git a/Makefile b/Makefile
index 1d5a4bc..63ba90f 100644
--- a/Makefile
+++ b/Makefile
@@ -9,7 +9,6 @@
#TARGET = linux24e
#TARGET = linux22
#TARGET = solaris
-#TARGET = openbsd
# pass CPU=<cpu_name> to make to optimize for a particular CPU
CPU = generic
@@ -54,10 +53,6 @@
COPTS.solaris = -fomit-frame-pointer -DENABLE_POLL -DFD_SETSIZE=65536
LIBS.solaris = -lnsl -lsocket
-# This is for OpenBSD 3.0
-COPTS.openbsd = -DENABLE_POLL
-LIBS.openbsd =
-
# CPU dependant optimizations
COPTS.generic = -O2
COPTS.i586 = -O2 -march=i586
@@ -77,14 +72,15 @@
LIBS.static-pcre=-L$(PCREDIR)/lib -Wl,-Bstatic -lpcreposix -lpcre -Wl,-Bdynamic
# you can enable debug arguments with "DEBUG=-g" or disable them with "DEBUG="
-#DEBUG = -g -DDEBUG_MEMORY
+#DEBUG = -g -DDEBUG_MEMORY -DDEBUG_FULL
DEBUG = -g
# if small memory footprint is required, you can reduce the buffer size. There
# are 2 buffers per concurrent session, so 16 kB buffers will eat 32 MB memory
# with 1000 concurrent sessions. Putting it slightly lower than a page size
-# will avoid the additionnal paramters to overflow a page.
-#SMALL_OPTS = -DBUFSIZE=8100 -DMAXREWRITE=1000 -DSYSTEM_MAXCONN=1024
+# will avoid the additionnal paramters to overflow a page. 8030 bytes is
+# exactly 5.5 TCP segments of 1460 bytes.
+#SMALL_OPTS = -DBUFSIZE=8030 -DMAXREWRITE=1030 -DSYSTEM_MAXCONN=1024
SMALL_OPTS =
# redefine this if you want to add some special PATH to include/libs
@@ -93,7 +89,10 @@
# set some defines when needed.
# Known ones are -DENABLE_POLL, -DENABLE_EPOLL, and -DUSE_MY_EPOLL
-DEFINE =
+# - use -DSTATTIME=0 to disable statistics, else specify an interval in
+# milliseconds.
+# - use -DTPROXY to compile with transparent proxy support.
+DEFINE = -DSTATTIME=0 -DTPROXY
# global options
TARGET_OPTS=$(COPTS.$(TARGET))
@@ -103,18 +102,11 @@
COPTS=-I. $(ADDINC) $(CPU_OPTS) $(TARGET_OPTS) $(REGEX_OPTS) $(SMALL_OPTS) $(DEFINE)
LIBS=$(LIBS.$(TARGET)) $(LIBS.$(REGEX)) $(ADDLIB)
-# - use -DSTATTIME=0 to disable statistics, else specify an interval in
-# milliseconds.
-# - use -DTPROXY to compile with transparent proxy support.
-CFLAGS = -Wall $(COPTS) $(DEBUG) -DSTATTIME=0 -DTPROXY
+CFLAGS = -Wall $(COPTS) $(DEBUG)
LDFLAGS = -g
all: haproxy
-# on OpenBSD, you have to do it this way :
-haproxy.bsd: src/list.o src/chtbl.o src/hashpjw.o haproxy.o
- $(LD) $(LDFLAGS) -o $@ $> $(LIBS)
-
haproxy: src/list.o src/chtbl.o src/hashpjw.o haproxy.o
$(LD) $(LDFLAGS) -o $@ $^ $(LIBS)