Added support for neutrino target to configure.in. Patch submitted by Jerry L. Kirk <Jerry.Kirk@Nexwarecorp.com>.

Split AR_FLAGS from AR for platforms that don't use the common syntax.
This commit is contained in:
cls%seawood.org 1999-11-23 06:23:52 +00:00
Родитель 112358a896
Коммит 6b4201d2ea
4 изменённых файлов: 91 добавлений и 36 удалений

Просмотреть файл

@ -23,7 +23,8 @@ CLASSIC_NSPR = @USE_NSPR_THREADS@
AS = @AS@
CC = @CC@
CCC = @CXX@
AR = @AR@ cr $@
AR = @AR@
AR_FLAGS = @AR_FLAGS@
RANLIB = @RANLIB@
PERL = @PERL@
DLLTOOL = @DLLTOOL@

Просмотреть файл

@ -267,8 +267,12 @@ $(LIBRARY): $(OBJS)
rm -f $@
ifdef XP_OS2_VACPP
$(AR) $(subst /,\\,$(OBJS)) $(AR_EXTRA_ARGS)
else
ifdef USE_AUTOCONF
$(AR) $(AR_FLAGS) $(OBJS) $(AR_EXTRA_ARGS)
else
$(AR) $(OBJS) $(AR_EXTRA_ARGS)
endif # USE_AUTOCONF
endif
$(RANLIB) $@

97
nsprpub/configure поставляемый
Просмотреть файл

@ -2244,6 +2244,7 @@ DLL_SUFFIX=so
MKSHLIB='$(CCC) -shared -o $@'
PR_MD_ASFILES=
PR_MD_CSRCS=
AR_FLAGS='cr $@'
case "$host" in
*-mingw*)
@ -2254,6 +2255,29 @@ case "$host" in
esac
case "$target" in
*-nto*)
cat >> confdefs.h <<\EOF
#define XP_UNIX 1
EOF
MDCPUCFG_H=_nto.cfg
PR_MD_CSRCS=nto.c
PR_MD_ARCH_DIR=unix
MKSHLIB='qcc -Vgcc_ntox86 -shared -Wl,-h$(@:$(OBJDIR)/%.so=%.so) -o $(@:$(OBJDIR)/%.so=%.so)'
CFLAGS="$CFLAGS -Wc,-Wall -Wc,-Wno-parentheses -DNTO -D_QNX_SOURCE -DHAVE_POINTER_LOCALTIME_R -shared"
OS_LIBS="-lsocket"
_OPTIMIZE_FLAGS="-O2"
_DEBUG_FLAGS="-O2 -gdwarf-2"
COMPILER_TAG="_qcc"
CC="qcc -Vgcc_ntox86 -w"
CXX="QCC -Vgcc_ntox86 -w"
CPP="qcc -Vgcc_ntox86 -w"
LD="qcc -Vgcc_ntox86 -nostdlib"
AR="qcc -Vgcc_ntox86 -M -a "
AR_FLAGS="$@"
;;
*-beos*)
cat >> confdefs.h <<\EOF
#define XP_BEOS 1
@ -2456,6 +2480,7 @@ EOF
;;
esac
;;
esac
if test "$enable_shared" = no; then
@ -2466,7 +2491,7 @@ fi
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
echo "configure:2470: checking how to run the C preprocessor" >&5
echo "configure:2495: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@ -2481,13 +2506,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
#line 2485 "configure"
#line 2510 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2491: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2516: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@ -2498,13 +2523,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
#line 2502 "configure"
#line 2527 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2508: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2533: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@ -2515,13 +2540,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
#line 2519 "configure"
#line 2544 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2525: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2550: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@ -2547,13 +2572,13 @@ echo "$ac_t""$CPP" 1>&6
if test $ac_cv_prog_gcc = yes; then
echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
echo "configure:2551: checking whether ${CC-cc} needs -traditional" >&5
echo "configure:2576: checking whether ${CC-cc} needs -traditional" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_pattern="Autoconf.*'x'"
cat > conftest.$ac_ext <<EOF
#line 2557 "configure"
#line 2582 "configure"
#include "confdefs.h"
#include <sgtty.h>
Autoconf TIOCGETP
@ -2571,7 +2596,7 @@ rm -f conftest*
if test $ac_cv_prog_gcc_traditional = no; then
cat > conftest.$ac_ext <<EOF
#line 2575 "configure"
#line 2600 "configure"
#include "confdefs.h"
#include <termio.h>
Autoconf TCGETA
@ -2595,12 +2620,12 @@ fi
for ac_func in lchown strerror
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:2599: checking for $ac_func" >&5
echo "configure:2624: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2604 "configure"
#line 2629 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@ -2623,7 +2648,7 @@ $ac_func();
; return 0; }
EOF
if { (eval echo configure:2627: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@ -2674,7 +2699,7 @@ fi
echo $ac_n "checking for pthread_attr_init in -lpthread""... $ac_c" 1>&6
echo "configure:2678: checking for pthread_attr_init in -lpthread" >&5
echo "configure:2703: checking for pthread_attr_init in -lpthread" >&5
ac_lib_var=`echo pthread'_'pthread_attr_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -2682,7 +2707,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lpthread $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2686 "configure"
#line 2711 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -2693,7 +2718,7 @@ int main() {
pthread_attr_init()
; return 0; }
EOF
if { (eval echo configure:2697: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2722: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -2712,7 +2737,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for pthread_attr_init in -lc_r""... $ac_c" 1>&6
echo "configure:2716: checking for pthread_attr_init in -lc_r" >&5
echo "configure:2741: checking for pthread_attr_init in -lc_r" >&5
ac_lib_var=`echo c_r'_'pthread_attr_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -2720,7 +2745,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lc_r $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2724 "configure"
#line 2749 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -2731,7 +2756,7 @@ int main() {
pthread_attr_init()
; return 0; }
EOF
if { (eval echo configure:2735: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -2750,7 +2775,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for pthread_attr_init in -lc""... $ac_c" 1>&6
echo "configure:2754: checking for pthread_attr_init in -lc" >&5
echo "configure:2779: checking for pthread_attr_init in -lc" >&5
ac_lib_var=`echo c'_'pthread_attr_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -2758,7 +2783,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lc $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2762 "configure"
#line 2787 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -2769,7 +2794,7 @@ int main() {
pthread_attr_init()
; return 0; }
EOF
if { (eval echo configure:2773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -2898,7 +2923,7 @@ if test -n "$USE_PTHREADS"; then
rm -f conftest*
ac_cv_have_dash_pthread=no
echo $ac_n "checking whether ${CC-cc} accepts -pthread""... $ac_c" 1>&6
echo "configure:2902: checking whether ${CC-cc} accepts -pthread" >&5
echo "configure:2927: checking whether ${CC-cc} accepts -pthread" >&5
echo 'int main() { return 0; }' | cat > conftest.c
${CC-cc} -pthread -o conftest conftest.c > conftest.out 2>&1
if test $? -eq 0; then
@ -2946,12 +2971,12 @@ EOF
esac
echo $ac_n "checking for pthread_create""... $ac_c" 1>&6
echo "configure:2950: checking for pthread_create" >&5
echo "configure:2975: checking for pthread_create" >&5
if eval "test \"`echo '$''{'ac_cv_func_pthread_create'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2955 "configure"
#line 2980 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char pthread_create(); below. */
@ -2974,7 +2999,7 @@ pthread_create();
; return 0; }
EOF
if { (eval echo configure:2978: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:3003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_pthread_create=yes"
else
@ -2993,7 +3018,7 @@ else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
echo "configure:2997: checking for pthread_create in -lpthread" >&5
echo "configure:3022: checking for pthread_create in -lpthread" >&5
ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -3001,7 +3026,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lpthread $LIBS"
cat > conftest.$ac_ext <<EOF
#line 3005 "configure"
#line 3030 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -3012,7 +3037,7 @@ int main() {
pthread_create()
; return 0; }
EOF
if { (eval echo configure:3016: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:3041: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -3068,12 +3093,12 @@ EOF
esac
echo $ac_n "checking for dlopen""... $ac_c" 1>&6
echo "configure:3072: checking for dlopen" >&5
echo "configure:3097: checking for dlopen" >&5
if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 3077 "configure"
#line 3102 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char dlopen(); below. */
@ -3096,7 +3121,7 @@ dlopen();
; return 0; }
EOF
if { (eval echo configure:3100: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:3125: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_dlopen=yes"
else
@ -3115,7 +3140,7 @@ else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
echo "configure:3119: checking for dlopen in -ldl" >&5
echo "configure:3144: checking for dlopen in -ldl" >&5
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -3123,7 +3148,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
#line 3127 "configure"
#line 3152 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -3134,7 +3159,7 @@ int main() {
dlopen()
; return 0; }
EOF
if { (eval echo configure:3138: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:3163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -3215,6 +3240,7 @@ fi
trap '' 1 2 15
@ -3459,6 +3485,7 @@ s%@LIB_SUFFIX@%$LIB_SUFFIX%g
s%@DLL_SUFFIX@%$DLL_SUFFIX%g
s%@MKSHLIB@%$MKSHLIB%g
s%@DEFINES@%$DEFINES%g
s%@AR_FLAGS@%$AR_FLAGS%g
s%@OS_LIBS@%$OS_LIBS%g
s%@EXTRA_LIBS@%$EXTRA_LIBS%g

Просмотреть файл

@ -218,6 +218,7 @@ DLL_SUFFIX=so
MKSHLIB='$(CCC) -shared -o $@'
PR_MD_ASFILES=
PR_MD_CSRCS=
AR_FLAGS='cr $@'
dnl ========================================================
dnl Override of system specific host options
@ -234,6 +235,26 @@ dnl ========================================================
dnl Override of system specific target options
dnl ========================================================
case "$target" in
*-nto*)
AC_DEFINE(XP_UNIX)
MDCPUCFG_H=_nto.cfg
PR_MD_CSRCS=nto.c
PR_MD_ARCH_DIR=unix
MKSHLIB='qcc -Vgcc_ntox86 -shared -Wl,-h$(@:$(OBJDIR)/%.so=%.so) -o $(@:$(OBJDIR)/%.so=%.so)'
CFLAGS="$CFLAGS -Wc,-Wall -Wc,-Wno-parentheses -DNTO -D_QNX_SOURCE -DHAVE_POINTER_LOCALTIME_R -shared"
OS_LIBS="-lsocket"
_OPTIMIZE_FLAGS="-O2"
_DEBUG_FLAGS="-O2 -gdwarf-2"
COMPILER_TAG="_qcc"
CC="qcc -Vgcc_ntox86 -w"
CXX="QCC -Vgcc_ntox86 -w"
CPP="qcc -Vgcc_ntox86 -w"
LD="qcc -Vgcc_ntox86 -nostdlib"
AR="qcc -Vgcc_ntox86 -M -a "
AR_FLAGS="$@"
;;
*-beos*)
AC_DEFINE(XP_BEOS)
AC_DEFINE(BeOS)
@ -379,6 +400,7 @@ case "$target" in
;;
esac
;;
esac
dnl Turn off shared libraries if asked to do so.
@ -685,6 +707,7 @@ AC_SUBST(MKSHLIB)
AC_SUBST(DEFINES)
AC_SUBST(DEFS)
AC_SUBST(AR)
AC_SUBST(AR_FLAGS)
AC_SUBST(DLLTOOL)
AC_SUBST(WINDRES)
AC_SUBST(RANLIB)