diff --git a/Makefile.Linux b/Makefile.Linux index 95ae311..ff763da 100644 --- a/Makefile.Linux +++ b/Makefile.Linux @@ -12,7 +12,7 @@ CC = gcc CFLAGS = -g -fPIC -O2 -fno-strict-aliasing -c -pthread -DWITHSPLICE -D_GNU_SOURCE -DGETHOSTBYNAME_R -D_THREAD_SAFE -D_REENTRANT -DNOODBC -DWITH_STD_MALLOC -DFD_SETSIZE=4096 -DWITH_POLL -DWITH_NETFILTER COUT = -o -LN = gcc +LN = $(CC) DCFLAGS = LDFLAGS = -fPIE -O2 -fno-strict-aliasing -pthread DLFLAGS = -shared diff --git a/Makefile.Solaris b/Makefile.Solaris index 414598e..8e84f20 100644 --- a/Makefile.Solaris +++ b/Makefile.Solaris @@ -11,7 +11,7 @@ BUILDDIR = ../bin/ CC = cc CFLAGS = -xO3 -c -D_SOLARIS -D_THREAD_SAFE -DGETHOSTBYNAME_R -D_REENTRANT -DNOODBC -DWITH_STD_MALLOC -DFD_SETSIZE=4096 -DWITH_POLL COUT = -o ./ -LN = cc +LN = $(CC) LDFLAGS = -xO3 DCFLAGS = -fPIC DLFLAGS = -shared diff --git a/Makefile.Solaris-gcc b/Makefile.Solaris-gcc index 6369337..6d3bba3 100644 --- a/Makefile.Solaris-gcc +++ b/Makefile.Solaris-gcc @@ -12,7 +12,7 @@ BUILDDIR = ../bin/ CC = gcc CFLAGS = -O2 -fno-strict-aliasing -c -D_SOLARIS -D_THREAD_SAFE -DGETHOSTBYNAME_R -D_REENTRANT -DNOODBC -DWITH_STD_MALLOC -DFD_SETSIZE=4096 -DWITH_POLL COUT = -o ./ -LN = gcc +LN = $(CC) LDFLAGS = -O3 DCFLAGS = -fPIC DLFLAGS = -shared diff --git a/Makefile.llvm b/Makefile.llvm index 849e099..a4d2115 100644 --- a/Makefile.llvm +++ b/Makefile.llvm @@ -12,7 +12,7 @@ BUILDDIR = ../bin/ CC = clang CFLAGS = -O2 -fno-strict-aliasing -c -pthread -static -DWITH_STD_MALLOC -DNOIPV6 COUT = -o -LN = clang +LN = $(CC) LDFLAGS = -O2 -fno-strict-aliasing -static -s DLFLAGS = -shared DLSUFFICS = .dll diff --git a/Makefile.openwrt-mips b/Makefile.openwrt-mips index 1e8e844..e6eecc5 100644 --- a/Makefile.openwrt-mips +++ b/Makefile.openwrt-mips @@ -12,7 +12,7 @@ CC = mips-openwrt-linux-gcc CFLAGS = -g -O2 -fno-strict-aliasing -c -pthread -DGETHOSTBYNAME_R -D_THREAD_SAFE -D_REENTRANT -DNOODBC -DWITH_STD_MALLOC -DFD_SETSIZE=4096 -DWITH_POLL -DWITH_NETFILTER COUT = -o -LN = mips-openwrt-linux-gcc +LN = $(CC) DCFLAGS = -fPIC LDFLAGS = -O2 -fno-strict-aliasing -pthread -s DLFLAGS = -shared diff --git a/Makefile.unix b/Makefile.unix index 6575aeb..742c5aa 100644 --- a/Makefile.unix +++ b/Makefile.unix @@ -13,7 +13,7 @@ CC = gcc # you may need -L/usr/pkg/lib for older NetBSD versions CFLAGS = -g -O2 -fno-strict-aliasing -c -pthread -D_THREAD_SAFE -D_REENTRANT -DNOODBC -DWITH_STD_MALLOC -DFD_SETSIZE=4096 -DWITH_POLL COUT = -o -LN = gcc +LN = $(CC) LDFLAGS = -O2 -fno-strict-aliasing -pthread # -lpthreads may be reuqired on some platforms instead of -pthreads # -ldl or -lld may be required for some platforms