diff options
author | Valentin Bartenev <vbart@nginx.com> | 2019-11-07 19:53:25 +0300 |
---|---|---|
committer | Valentin Bartenev <vbart@nginx.com> | 2019-11-07 19:53:25 +0300 |
commit | cc825477824883a10766446eeb0dc0d3785a63ee (patch) | |
tree | ce40090ca2e8165064dbba42173d2c85ef847e16 /auto/os | |
parent | 5d42599e3318aa8f68a3cbb4b992985cc75495dc (diff) | |
download | unit-cc825477824883a10766446eeb0dc0d3785a63ee.tar.gz unit-cc825477824883a10766446eeb0dc0d3785a63ee.tar.bz2 |
Respecting AR environment variable to configure ar binary.
Diffstat (limited to '')
-rw-r--r-- | auto/os/conf | 24 | ||||
-rw-r--r-- | auto/os/test | 9 |
2 files changed, 21 insertions, 12 deletions
diff --git a/auto/os/conf b/auto/os/conf index 1e298ecd..02c4afaf 100644 --- a/auto/os/conf +++ b/auto/os/conf @@ -21,7 +21,7 @@ case "$NXT_SYSTEM" in Linux) nxt_have=NXT_LINUX . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared -Wl,-soname,libnxt.so" NXT_SHARED_LOCAL_LINK="\$(CC) -shared \ -Wl,-soname,\\\$\$ORIGIN/libnxt.so" @@ -44,7 +44,7 @@ case "$NXT_SYSTEM" in FreeBSD) nxt_have=NXT_FREEBSD . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared -Wl,-soname,libnxt.so" NXT_SHARED_LOCAL_LINK="\$(CC) -shared \ -Wl,-soname,\\\$\$ORIGIN/libnxt.so" @@ -71,14 +71,14 @@ case "$NXT_SYSTEM" in case "$NXT_CC_NAME" in SunC): - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -G -h libnxt.so" NXT_SHARED_LOCAL_LINK="\$(CC) -G -h \\\$\$ORIGIN/libnxt.so" NXT_MODULE_LINK="\$(CC) -G" ;; *) - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared -Wl,-soname,libnxt.so" NXT_SHARED_LOCAL_LINK="\$(CC) -shared \ -Wl,-soname,\\\$\$ORIGIN/libnxt.so" @@ -106,7 +106,7 @@ case "$NXT_SYSTEM" in # HFS+ volumes are caseless by default. nxt_have=NXT_HAVE_CASELESS_FILESYSTEM . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -dynamiclib" NXT_SHARED_LOCAL_LINK="\$(CC) -dynamiclib \ -install_name @executable_path/libnxt.dylib" @@ -130,7 +130,7 @@ case "$NXT_SYSTEM" in NetBSD) nxt_have=NXT_NETBSD . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared" NXT_SHARED_LOCAL_LINK="\$(CC) -shared" NXT_MODULE_LINK="\$(CC) -shared" @@ -152,7 +152,7 @@ case "$NXT_SYSTEM" in OpenBSD) nxt_have=NXT_OPENBSD . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared" NXT_SHARED_LOCAL_LINK="\$(CC) -shared" NXT_MODULE_LINK="\$(CC) -shared" @@ -174,7 +174,7 @@ case "$NXT_SYSTEM" in DragonFly) nxt_have=NXT_DRAGONFLY . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared" NXT_SHARED_LOCAL_LINK="\$(CC) -shared" NXT_MODULE_LINK="\$(CC) -shared" @@ -196,7 +196,7 @@ case "$NXT_SYSTEM" in AIX) nxt_have=NXT_AIX . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -G" NXT_SHARED_LOCAL_LINK="\$(CC) -G" NXT_MODULE_LINK="\$(CC) -G" @@ -220,7 +220,7 @@ case "$NXT_SYSTEM" in NXT_EXEC_LINK="\$(CC)" NXT_SHARED_LOCAL_EXEC_LINK= - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared" NXT_SHARED_LOCAL_LINK="\$(CC) -shared" NXT_MODULE_LINK="\$(CC) -shared" @@ -238,7 +238,7 @@ case "$NXT_SYSTEM" in QNX) nxt_have=NXT_QNX . auto/have - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared" NXT_SHARED_LOCAL_LINK="\$(CC) -shared" NXT_MODULE_LINK="\$(CC) -shared" @@ -257,7 +257,7 @@ case "$NXT_SYSTEM" in ;; *) - NXT_STATIC_LINK="ar -r -c" + NXT_STATIC_LINK="\$(AR) -r -c" NXT_SHARED_LINK="\$(CC) -shared" NXT_SHARED_LOCAL_LINK="\$(CC) -shared" NXT_MODULE_LINK="\$(CC) -shared" diff --git a/auto/os/test b/auto/os/test index 3188d3db..c37700a6 100644 --- a/auto/os/test +++ b/auto/os/test @@ -14,6 +14,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -m 2>/dev/null` echo=echo CC=${CC:-cc} + AR=${AR:-ar} ;; FreeBSD | NetBSD | OpenBSD | DragonFly) @@ -21,6 +22,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -m 2>/dev/null` echo=echo CC=${CC:-cc} + AR=${AR:-ar} ;; SunOS) @@ -28,6 +30,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -p 2>/dev/null` echo=echo CC=${CC:-gcc} + AR=${AR:-ar} NXT_TEST_CFLAGS="$NXT_TEST_CFLAGS -D_XOPEN_SOURCE" NXT_TEST_CFLAGS="$NXT_TEST_CFLAGS -D_XOPEN_SOURCE_EXTENDED=1" @@ -40,6 +43,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -m 2>/dev/null` echo=echo CC=${CC:-cc} + AR=${AR:-ar} ;; AIX) @@ -47,6 +51,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -p 2>/dev/null` echo=echo CC=${CC:-gcc} + AR=${AR:-ar} ;; HP-UX) @@ -54,6 +59,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -m 2>/dev/null` echo=echo CC=${CC:-gcc} + AR=${AR:-ar} NXT_TEST_CFLAGS="$NXT_TEST_CFLAGS -D_XOPEN_SOURCE" NXT_TEST_CFLAGS="$NXT_TEST_CFLAGS -D_XOPEN_SOURCE_EXTENDED" @@ -65,6 +71,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -p 2>/dev/null` echo=echo CC=${CC:-gcc} + AR=${AR:-ar} ;; MINGW*) @@ -76,6 +83,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -m 2>/dev/null` echo=auto/echo/echo.exe CC=${CC:-cl} + AR=${AR:-ar} NXT_WINDOWS=YES ;; @@ -84,6 +92,7 @@ case "$NXT_SYSTEM" in NXT_SYSTEM_PLATFORM=`uname -p 2>/dev/null` echo=echo CC=${CC:-gcc} + AR=${AR:-ar} ;; esac |