OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [newlib-1.17.0/] [libgloss/] [libnosys/] [configure.in] - Blame information for rev 148

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 148 jeremybenn
# Copyright (c) 1995, 1996 Cygnus Support
2
#
3
# The authors hereby grant permission to use, copy, modify, distribute,
4
# and license this software and its documentation for any purpose, provided
5
# that existing copyright notices are retained in all copies and that this
6
# notice is included verbatim in any distributions. No written agreement,
7
# license, or royalty fee is required for any of the authorized uses.
8
# Modifications to this software may be copyrighted by their authors
9
# and need not follow the licensing terms described here, provided that
10
# the new terms are clearly indicated on the first page of each file where
11
# they apply.
12
#
13
# Process this file with autoconf to produce a configure script.
14
#
15
AC_PREREQ(2.59)
16
AC_INIT(close.c)
17
AC_CONFIG_HEADER(config.h)
18
 
19
if test "${enable_shared}" = "yes" ; then
20
    echo "Shared libraries not supported for cross compiling, ignored"
21
fi
22
 
23
if test "$srcdir" = "." ; then
24
  if test "${with_target_subdir}" != "." ; then
25
    libgloss_topdir="${srcdir}/${with_multisrctop}../../.."
26
  else
27
    libgloss_topdir="${srcdir}/${with_multisrctop}../.."
28
  fi
29
else
30
  libgloss_topdir="${srcdir}/../.."
31
fi
32
AC_CONFIG_AUX_DIR($libgloss_topdir)
33
 
34
AC_CANONICAL_SYSTEM
35
AC_ARG_PROGRAM
36
 
37
AC_PROG_INSTALL
38
 
39
AC_DEFINE(HAVE_GNU_LD)
40
dnl Make sure syscall names match those being used by newlib
41
case "${target}" in
42
  *-*-cygwin*)
43
        ;;
44
  a29k-amd-udi)
45
        ;;
46
  arc-*-*)
47
        ;;
48
  arm-*-pe)
49
        ;;
50
  arm-*-*)
51
        ;;
52
  strongarm-*-*)
53
        ;;
54
  bfin-*-*)
55
        ;;
56
  cris-*-* | crisv32-*-*)
57
        ;;
58
  d10v*)
59
        ;;
60
  h8300*-*-*)
61
        ;;
62
  h8500-*-*)
63
        ;;
64
  i[3456]86-*-sco*)
65
        ;;
66
  lm32-*-*)
67
        ;;
68
  m32r-*-*)
69
        ;;
70
  mn10?00-*-*)
71
        ;;
72
  powerpcle-*-pe)
73
        ;;
74
  sh*-*-*)
75
        ;;
76
  sparc-sun-sunos*)
77
        ;;
78
  sparc64-*-*)
79
        ;;
80
  thumb-*-pe)
81
        ;;
82
  thumb-*-*)
83
        ;;
84
  v850-*-*)
85
        ;;
86
  v850e-*-*)
87
        ;;
88
  v850ea-*-*)
89
        ;;
90
  w65-*-*)
91
        ;;
92
  xstormy16-*-*)
93
        ;;
94
  z8k-*-*)
95
        ;;
96
  *)
97
        AC_DEFINE(MISSING_SYSCALL_NAMES)
98
        ;;
99
esac
100
 
101
dnl Make sure we know if elf format used
102
case "${target}" in
103
  *-*-elf)
104
        AC_DEFINE(HAVE_ELF)
105
 
106
        AC_CACHE_CHECK([for .previous assembler directive],
107
                         libc_cv_asm_previous_directive, [dnl
108
        libc_cv_asm_previous_directive=no
109
        cat > conftest.s <
110
.section foo_section
111
.previous
112
EOF
113
        if AC_TRY_COMMAND(${CC-cc} -c $CFLAGS conftest.s 1>&AC_FD_CC); then
114
          libc_cv_asm_previous_directive=yes
115
        fi
116
        rm -f conftest*])
117
 
118
        if test "x${libc_cv_asm_previous_directive}" = "xyes"; then
119
          AC_DEFINE(HAVE_ASM_PREVIOUS_DIRECTIVE)
120
        fi
121
 
122
        AC_CACHE_CHECK([for .popsection assembler directive],
123
                         libc_cv_asm_popsection_directive, [dnl
124
        libc_cv_asm_popsection_directive=no
125
        cat > conftest.s <
126
.pushsection foo_section
127
.popsection
128
EOF
129
        if AC_TRY_COMMAND(${CC-cc} -c $CFLAGS conftest.s 1>&AC_FD_CC); then
130
          libc_cv_asm_popsection_directive=yes
131
        fi
132
        rm -f conftest*])
133
 
134
        if test "x${libc_cv_asm_popsection_directive}" = "xyes"; then
135
          AC_DEFINE(HAVE_ASM_POPSECTION_DIRECTIVE)
136
        fi
137
 
138
        AC_CACHE_CHECK([for section attributes],
139
                         libc_cv_section_attributes, [dnl
140
        libc_cv_section_attributes=no
141
        cat > conftest.c <
142
int secttest __attribute__ ((section (".gnu.warning.secttest"))) = 10;
143
int main() {}
144
EOF
145
        if AC_TRY_COMMAND(${CC-cc} -c $CFLAGS conftest.c 1>&AC_FD_CC); then
146
          libc_cv_section_attributes=yes
147
        fi
148
        rm -f conftest*])
149
        if test "x${libc_cv_section_attributes}" = "xyes"; then
150
          AC_DEFINE(HAVE_SECTION_ATTRIBUTES)
151
        fi
152
        ;;
153
esac
154
 
155
AC_CACHE_CHECK([for symbol prefix], libc_symbol_prefix, [dnl
156
cat > conftest.c <<\EOF
157
foo () { }
158
EOF
159
dnl
160
libc_symbol_prefix=none
161
if AC_TRY_COMMAND([${CC-cc} -S conftest.c -o - | fgrep "\$foo" > /dev/null]);
162
then
163
  libc_symbol_prefix='$'
164
else
165
  if AC_TRY_COMMAND([${CC-cc} -S conftest.c -o - | fgrep "_foo" > /dev/null]);
166
  then
167
    libc_symbol_prefix=_
168
  fi
169
fi
170
rm -f conftest* ])
171
if test $libc_symbol_prefix != none; then
172
  AC_DEFINE_UNQUOTED(__SYMBOL_PREFIX, "$libc_symbol_prefix")
173
else
174
  AC_DEFINE(__SYMBOL_PREFIX, "")
175
fi
176
 
177
LIB_AC_PROG_CC
178
AS=${AS-as}
179
AC_SUBST(AS)
180
AR=${AR-ar}
181
AC_SUBST(AR)
182
LD=${LD-ld}
183
AC_SUBST(LD)
184
AC_PROG_RANLIB
185
LIB_AM_PROG_AS
186
 
187
host_makefile_frag=${srcdir}/../config/default.mh
188
 
189
dnl We have to assign the same value to other variables because autoconf
190
dnl doesn't provide a mechanism to substitute a replacement keyword with
191
dnl arbitrary data or pathnames.
192
dnl
193
host_makefile_frag_path=$host_makefile_frag
194
AC_SUBST(host_makefile_frag_path)
195
AC_SUBST_FILE(host_makefile_frag)
196
 
197
AC_CONFIG_FILES(Makefile,
198
ac_file=Makefile . ${libgloss_topdir}/config-ml.in,
199
srcdir=${srcdir}
200
target=${target}
201
with_multisubdir=${with_multisubdir}
202
ac_configure_args="${ac_configure_args} --enable-multilib"
203
CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
204
libgloss_topdir=${libgloss_topdir}
205
)
206
AC_OUTPUT
207
 
208
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.