FS-6375 adding LTCFLAGS makes configure choose the proper pre post deps on both 32bit and 64bit just work out of the box

This commit is contained in:
Brian West 2014-03-19 04:04:38 -05:00
parent c9757f72a5
commit 148f67e061
1 changed files with 21 additions and 2 deletions

View File

@ -299,9 +299,15 @@ elif test "x${ax_cv_c_compiler_vendor}" = "xgnu" ; then
case "$host" in
*darwin12.*|*darwin11.*|*darwin10.*|*darwin9.*|*darwin8.*)
APR_ADDTO(CFLAGS, -arch x86_64)
APR_ADDTO(LDFLAGS, -arch x86_64)
APR_ADDTO(CXXFLAGS, -arch x86_64)
APR_ADDTO(LDFLAGS, -arch x86_64)
APR_ADDTO(CXXFLAGS, -arch x86_64)
;;
*-solaris2*)
APR_ADDTO(CFLAGS, -m64)
APR_ADDTO(LTCFLAGS, -m64)
APR_ADDTO(LDFLAGS, -m64)
APR_ADDTO(CXXFLAGS, -m64)
;;
*)
LIBS="$LIBS -m64"
;;
@ -565,6 +571,19 @@ case "$host" in
APR_ADDTO([PLATFORM_CORE_LIBS], [-ldl])
;;
*-solaris2*)
if test "${enable_64}" = "yes"; then
APR_ADDTO(CFLAGS, [-I/opt/64/include])
APR_ADDTO(LTCFLAGS, [-I/opt/64/include])
APR_ADDTO(CXXFLAGS, [-I/opt/64/include])
APR_ADDTO(LDFLAGS, [-L/opt/64/lib -Wl,-rpath,/opt/64/lib])
else
APR_ADDTO(CFLAGS, [-I/opt/include])
APR_ADDTO(LTCFLAGS, [-I/opt/include])
APR_ADDTO(CXXFLAGS, -I/opt/include)
APR_ADDTO(LDFLAGS, [-L/opt/lib -Wl,-rpath,/opt/lib])
APR_ADDTO(SWITCH_AM_CFLAGS, [-I/opt/include])
APR_ADDTO(SWITCH_AM_LDFLAGS, [-L/opt/lib -Wl,-rpath,/opt/lib])
fi
APR_ADDTO(SWITCH_AM_CFLAGS, -DPATH_MAX=2048 -D__EXTENSIONS__)
APR_ADDTO(SWITCH_AM_LDFLAGS, -lsendfile -lresolv -lsocket -lnsl -luuid)
APR_ADDTO(ESL_LDFLAGS, -lnsl -lsocket)