зеркало из https://github.com/mozilla/pjs.git
r=mark smith OS/2 changes for GCC 3.2.2
This commit is contained in:
Родитель
7f12986477
Коммит
4141b45420
|
@ -4362,30 +4362,29 @@ EOF
|
|||
|
||||
cat >> confdefs.h <<\EOF
|
||||
#define OS2 1
|
||||
EOF
|
||||
|
||||
cat >> confdefs.h <<\EOF
|
||||
#define TCPV40HDRS 1
|
||||
EOF
|
||||
|
||||
AR=emxomfar
|
||||
AR_FLAGS='-p256 r $@'
|
||||
AR_FLAGS='r $@'
|
||||
LD='$(CC)'
|
||||
CFLAGS="$CFLAGS -Wall -Zmtd -Zomf"
|
||||
CXXFLAGS="$CFLAGS -Wall -Zmtd -Zomf"
|
||||
CFLAGS="$CFLAGS -Wall -Zomf"
|
||||
CXXFLAGS="$CFLAGS -Wall -Zomf"
|
||||
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
|
||||
DSO_CFLAGS=
|
||||
DSO_LDOPTS='-Zomf -Zdll -Zmtd'
|
||||
DSO_LDOPTS='-Zomf -Zdll'
|
||||
_OPTIMIZE_FLAGS=-O3
|
||||
_DEBUG_FLAGS="-g -fno-inline"
|
||||
if test -n "$MOZ_OPTIMIZE"; then
|
||||
DSO_LDOPTS="$DSO_LDOPTS -Zlinker /EXEPACK:2 -Zlinker /PACKCODE -Zlinker /PACKDATA"
|
||||
fi
|
||||
OS_LIBS="-lsocket -lemxio"
|
||||
OS_LIBS="-lsocket"
|
||||
IMPLIB='emximp -o'
|
||||
FILTER='emxexp -o'
|
||||
|
||||
if test -z "$EMXOMFLD_LINKER"; then
|
||||
# using LINK386.EXE
|
||||
DSO_LDOPTS="$DSO_LDOPTS -Zlinker /NOO"
|
||||
fi
|
||||
|
||||
# GCC for OS/2 currently predefines these, but we don't want them
|
||||
DEFINES="$DEFINES -Uunix -U__unix -U__unix__"
|
||||
|
||||
|
@ -4458,17 +4457,17 @@ EOF
|
|||
|
||||
ac_safe=`echo "machine/builtins.h" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for machine/builtins.h""... $ac_c" 1>&6
|
||||
echo "configure:4462: checking for machine/builtins.h" >&5
|
||||
echo "configure:4461: checking for machine/builtins.h" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 4467 "configure"
|
||||
#line 4466 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <machine/builtins.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:4472: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:4471: \"$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
|
||||
rm -rf conftest*
|
||||
|
@ -4866,12 +4865,12 @@ esac
|
|||
if test -z "$SKIP_LIBRARY_CHECKS"; then
|
||||
|
||||
echo $ac_n "checking for dlopen""... $ac_c" 1>&6
|
||||
echo "configure:4870: checking for dlopen" >&5
|
||||
echo "configure:4869: 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 4875 "configure"
|
||||
#line 4874 "configure"
|
||||
#include "confdefs.h"
|
||||
/* System header to define __stub macros and hopefully few prototypes,
|
||||
which can conflict with char dlopen(); below. */
|
||||
|
@ -4894,7 +4893,7 @@ dlopen();
|
|||
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:4898: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:4897: \"$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
|
||||
|
@ -4913,7 +4912,7 @@ else
|
|||
echo "$ac_t""no" 1>&6
|
||||
|
||||
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
|
||||
echo "configure:4917: checking for dlopen in -ldl" >&5
|
||||
echo "configure:4916: 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
|
||||
|
@ -4921,7 +4920,7 @@ else
|
|||
ac_save_LIBS="$LIBS"
|
||||
LIBS="-ldl $LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 4925 "configure"
|
||||
#line 4924 "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
|
||||
|
@ -4932,7 +4931,7 @@ int main() {
|
|||
dlopen()
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:4936: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:4935: \"$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
|
||||
|
@ -4960,13 +4959,13 @@ fi
|
|||
|
||||
if test $ac_cv_prog_gcc = yes; then
|
||||
echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
|
||||
echo "configure:4964: checking whether ${CC-cc} needs -traditional" >&5
|
||||
echo "configure:4963: 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 4970 "configure"
|
||||
#line 4969 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sgtty.h>
|
||||
Autoconf TIOCGETP
|
||||
|
@ -4984,7 +4983,7 @@ rm -f conftest*
|
|||
|
||||
if test $ac_cv_prog_gcc_traditional = no; then
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 4988 "configure"
|
||||
#line 4987 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <termio.h>
|
||||
Autoconf TCGETA
|
||||
|
@ -5008,12 +5007,12 @@ fi
|
|||
for ac_func in lchown strerror
|
||||
do
|
||||
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
|
||||
echo "configure:5012: checking for $ac_func" >&5
|
||||
echo "configure:5011: 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 5017 "configure"
|
||||
#line 5016 "configure"
|
||||
#include "confdefs.h"
|
||||
/* System header to define __stub macros and hopefully few prototypes,
|
||||
which can conflict with char $ac_func(); below. */
|
||||
|
@ -5036,7 +5035,7 @@ $ac_func();
|
|||
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:5040: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:5039: \"$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
|
||||
|
@ -5074,7 +5073,7 @@ fi
|
|||
|
||||
|
||||
echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6
|
||||
echo "configure:5078: checking for pthread_create in -lpthreads" >&5
|
||||
echo "configure:5077: checking for pthread_create in -lpthreads" >&5
|
||||
echo "
|
||||
#include <pthread.h>
|
||||
void *foo(void *v) { int a = 1; }
|
||||
|
@ -5096,7 +5095,7 @@ echo "
|
|||
echo "$ac_t""no" 1>&6
|
||||
|
||||
echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
|
||||
echo "configure:5100: checking for pthread_create in -lpthread" >&5
|
||||
echo "configure:5099: checking for pthread_create in -lpthread" >&5
|
||||
echo "
|
||||
#include <pthread.h>
|
||||
void *foo(void *v) { int a = 1; }
|
||||
|
@ -5118,7 +5117,7 @@ echo "
|
|||
echo "$ac_t""no" 1>&6
|
||||
|
||||
echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6
|
||||
echo "configure:5122: checking for pthread_create in -lc_r" >&5
|
||||
echo "configure:5121: checking for pthread_create in -lc_r" >&5
|
||||
echo "
|
||||
#include <pthread.h>
|
||||
void *foo(void *v) { int a = 1; }
|
||||
|
@ -5140,7 +5139,7 @@ echo "
|
|||
echo "$ac_t""no" 1>&6
|
||||
|
||||
echo $ac_n "checking for pthread_create in -lc""... $ac_c" 1>&6
|
||||
echo "configure:5144: checking for pthread_create in -lc" >&5
|
||||
echo "configure:5143: checking for pthread_create in -lc" >&5
|
||||
echo "
|
||||
#include <pthread.h>
|
||||
void *foo(void *v) { int a = 1; }
|
||||
|
@ -5290,7 +5289,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:5294: checking whether ${CC-cc} accepts -pthread" >&5
|
||||
echo "configure:5293: 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
|
||||
|
@ -5306,7 +5305,7 @@ echo "configure:5294: checking whether ${CC-cc} accepts -pthread" >&5
|
|||
ac_cv_have_dash_pthreads=no
|
||||
if test "$ac_cv_have_dash_pthread" = "no"; then
|
||||
echo $ac_n "checking whether ${CC-cc} accepts -pthreads""... $ac_c" 1>&6
|
||||
echo "configure:5310: checking whether ${CC-cc} accepts -pthreads" >&5
|
||||
echo "configure:5309: checking whether ${CC-cc} accepts -pthreads" >&5
|
||||
echo 'int main() { return 0; }' | cat > conftest.c
|
||||
${CC-cc} -pthreads -o conftest conftest.c > conftest.out 2>&1
|
||||
if test $? -eq 0; then
|
||||
|
|
|
@ -1506,28 +1506,24 @@ mips-sony-newsos*)
|
|||
# AC_DEFINE(USE_OS2_TOOLKIT_HEADERS)
|
||||
AC_DEFINE(XP_OS2_EMX)
|
||||
AC_DEFINE(OS2)
|
||||
AC_DEFINE(TCPV40HDRS)
|
||||
AR=emxomfar
|
||||
AR_FLAGS='-p256 r $@'
|
||||
AR_FLAGS='r $@'
|
||||
LD='$(CC)'
|
||||
CFLAGS="$CFLAGS -Wall -Zmtd -Zomf"
|
||||
CXXFLAGS="$CFLAGS -Wall -Zmtd -Zomf"
|
||||
CFLAGS="$CFLAGS -Wall -Zomf"
|
||||
CXXFLAGS="$CFLAGS -Wall -Zomf"
|
||||
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
|
||||
DSO_CFLAGS=
|
||||
DSO_LDOPTS='-Zomf -Zdll -Zmtd'
|
||||
DSO_LDOPTS='-Zomf -Zdll'
|
||||
_OPTIMIZE_FLAGS=-O3
|
||||
_DEBUG_FLAGS="-g -fno-inline"
|
||||
if test -n "$MOZ_OPTIMIZE"; then
|
||||
DSO_LDOPTS="$DSO_LDOPTS -Zlinker /EXEPACK:2 -Zlinker /PACKCODE -Zlinker /PACKDATA"
|
||||
fi
|
||||
OS_LIBS="-lsocket -lemxio"
|
||||
OS_LIBS="-lsocket"
|
||||
IMPLIB='emximp -o'
|
||||
FILTER='emxexp -o'
|
||||
|
||||
if test -z "$EMXOMFLD_LINKER"; then
|
||||
# using LINK386.EXE
|
||||
DSO_LDOPTS="$DSO_LDOPTS -Zlinker /NOO"
|
||||
fi
|
||||
|
||||
# GCC for OS/2 currently predefines these, but we don't want them
|
||||
DEFINES="$DEFINES -Uunix -U__unix -U__unix__"
|
||||
|
||||
|
|
|
@ -193,10 +193,14 @@ print_export {
|
|||
}
|
||||
|
||||
# finally, print out an appropriate export line
|
||||
if ( $type eq "Win32" || $type eq "OS2" ) {
|
||||
if ( $type eq "Win32" ) {
|
||||
if ( $symtype ne "G" ) {
|
||||
print "\t$symbol\t\t\@$ordinal\n";
|
||||
}
|
||||
} elsif ( $type eq "OS2" ) {
|
||||
if ( $symtype ne "G" ) {
|
||||
print "\t_$symbol\t\t\@$ordinal\n";
|
||||
}
|
||||
} elsif ( $type eq "Win16" ) {
|
||||
if ( $symtype eq "C" ) {
|
||||
print "\t_$symbol\t\t\@$ordinal\n";
|
||||
|
|
|
@ -342,7 +342,10 @@ extern char *strdup();
|
|||
#define BSD_TIME 1 /* for servers/slapd/log.h */
|
||||
#endif /* sunos4 || osf */
|
||||
|
||||
#if !defined(_WINDOWS) && !defined(macintosh) && !defined(XP_OS2)
|
||||
#if defined(XP_OS2)
|
||||
#include <machine/endian.h> /* for htonl, et.al. */
|
||||
#include <arpa/inet.h> /* for inet_addr() */
|
||||
#elif !defined(_WINDOWS) && !defined(macintosh)
|
||||
#include <netinet/in.h>
|
||||
#if !defined(XP_BEOS)
|
||||
#include <arpa/inet.h> /* for inet_addr() */
|
||||
|
|
Загрузка…
Ссылка в новой задаче