From d88c927ba94d4a2a22764fec8d0f57d89a782c71 Mon Sep 17 00:00:00 2001 From: z3APA3A <3APA3A@3proxy.ru> Date: Fri, 20 Nov 2020 14:19:47 +0300 Subject: [PATCH] allow overwrite CC for linking --- Makefile.Linux | 2 +- Makefile.Solaris | 2 +- Makefile.Solaris-gcc | 2 +- Makefile.llvm | 2 +- Makefile.openwrt-mips | 2 +- Makefile.unix | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) 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 6ceb0a6..c263590 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 a10908f..9696c61 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 7dbc086..00a3df4 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 f6e723a..6ed587a 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 0063b4d..4985972 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