newlib: drop i?86-pc-linux-* target support
This was added 20+ years ago. It seems to have very few (or no users) as it only works on 32-bit x86 GNU/Linux (i.e. glibc) systems, and even then only with old versions of glibc. It hasn't compiled in at least 5 years, but most likely been broken for more like 15 years -- it relies on internal glibc APIs (like linuxthreads), and that code has changed and been deleted significantly since. This single target ends up dragging in a lot of non-trivial code that is hard to keep working, and currently impossible to verify -- the libtool and iconvdata and sys/linux/ code isn't used by anything else, but ends up touching just about every build file in the tree. Punt the target so we can start stripping out all these unique code paths. This commit by itself just disables the target. We'll start deleting the individual unused pieces in followups.
This commit is contained in:
parent
492e5fe8b0
commit
462d6942f6
|
@ -1,3 +1,7 @@
|
|||
*** Major changes in newlib version 4.3.0:
|
||||
|
||||
- remove i?86-pc-linux-gnu support
|
||||
|
||||
*** Major changes in newlib version 4.2.0:
|
||||
|
||||
- remove use of --cygnus option for automake
|
||||
|
|
|
@ -508,40 +508,6 @@ need to add the other targets you're testing to the case statement.
|
|||
Now type make check-target-newlib in the top-level build directory to
|
||||
run the testsuite.
|
||||
|
||||
Shared newlib
|
||||
=============
|
||||
|
||||
newlib uses libtool when it is being compiled natively (with
|
||||
--target=i[34567]86-pc-linux-gnu) on an i[34567]86-pc-linux-gnu
|
||||
host. This allows newlib to be compiled as a shared library.
|
||||
|
||||
To configure newlib, do the following from your build directory:
|
||||
|
||||
$(source_dir)/src/configure --with-newlib --prefix=$(install_dir)
|
||||
|
||||
configure will recognize that host == target ==
|
||||
i[34567]86-pc-linux-gnu, so it will tell newlib to compile itself using
|
||||
libtool. By default, libtool will build shared and static versions of
|
||||
newlib.
|
||||
|
||||
To compile a program against shared newlib, do the following (where
|
||||
target_install_dir = $(install_dir)/i[34567]86-pc-linux-gnu):
|
||||
|
||||
gcc -nostdlib $(target_install_dir)/lib/crt0.o progname.c -I $(target_install_dir)/include -L $(target_install_dir)/lib -lc -lm -lgcc
|
||||
|
||||
To run the program, make sure that $(target_install_dir)/lib is listed
|
||||
in the LD_LIBRARY_PATH environment variable.
|
||||
|
||||
To create a static binary linked against newlib, do the following:
|
||||
|
||||
gcc -nostdlib -static $(target_install_dir)/lib/crt0.o progname.c -I $(target_install_dir)/include -L $(target_install_dir)/lib -lc -lm
|
||||
|
||||
libtool can be instructed to produce only static libraries. To build
|
||||
newlib as a static library only, do the following from your build
|
||||
directory:
|
||||
|
||||
$(source_dir)/src/configure --with-newlib --prefix=$(install_dir) --disable-shared
|
||||
|
||||
Regenerating Configuration Files
|
||||
================================
|
||||
|
||||
|
|
|
@ -12076,11 +12076,6 @@ fi
|
|||
|
||||
|
||||
HAVE_ICONVDATA=false
|
||||
case $host in
|
||||
i[34567]86-pc-linux-*)
|
||||
HAVE_ICONVDATA=true
|
||||
;;
|
||||
esac
|
||||
if $HAVE_ICONVDATA; then
|
||||
HAVE_ICONVDATA_TRUE=
|
||||
HAVE_ICONVDATA_FALSE='#'
|
||||
|
|
|
@ -348,11 +348,6 @@ AM_CONDITIONAL(HAVE_DOC, test x$have_multisubdir = xno)
|
|||
AM_CONDITIONAL(HAVE_MULTISUBDIR, test x$have_multisubdir = xyes)
|
||||
|
||||
HAVE_ICONVDATA=false
|
||||
case $host in
|
||||
i[[34567]]86-pc-linux-*)
|
||||
HAVE_ICONVDATA=true
|
||||
;;
|
||||
esac
|
||||
AM_CONDITIONAL([HAVE_ICONVDATA], $HAVE_ICONVDATA)
|
||||
|
||||
CRT0=
|
||||
|
|
|
@ -406,7 +406,7 @@ fi
|
|||
|
||||
if [ "x${newlib_mb}" = "x" ]; then
|
||||
case "${host}" in
|
||||
i[34567]86-pc-linux-*|*-*-cygwin*)
|
||||
*-*-cygwin*)
|
||||
newlib_mb=yes
|
||||
;;
|
||||
esac
|
||||
|
@ -418,21 +418,6 @@ if [ "${newlib_io_float}" = "no" ] ; then
|
|||
newlib_cflags="${newlib_cflags} -DNO_FLOATING_POINT"
|
||||
fi
|
||||
|
||||
# Verify if shared newlib support is allowed and set appropriate variables
|
||||
# We don't want to use libtool for platforms that we are not going to
|
||||
# support shared libraries. This is because it adds executable tests which
|
||||
# we don't want for most embedded platforms.
|
||||
case "${host}" in
|
||||
i[34567]86-pc-linux-*)
|
||||
use_libtool=yes
|
||||
have_sys_mach_dir=yes
|
||||
stdio64_dir=stdio64
|
||||
oext=lo
|
||||
lpfx=
|
||||
aext=la ;;
|
||||
*) ;; #shared library not supported for ${host}
|
||||
esac
|
||||
|
||||
# Get the source directories to use for the host. unix_dir is set
|
||||
# to unix to get some standard Unix routines. posix_dir is set to get some
|
||||
# standard Posix routines. sys_dir should supply system dependent routines
|
||||
|
@ -530,29 +515,6 @@ case "${host}" in
|
|||
sys_dir=sysvi386
|
||||
unix_dir=unix
|
||||
;;
|
||||
i[34567]86-pc-linux-*)
|
||||
sys_dir=linux
|
||||
unix_dir=unix
|
||||
posix_dir=posix
|
||||
crt1=crt1.o
|
||||
crt1_dir=libc/sys/${sys_dir}
|
||||
gcc_dir=`gcc -print-search-dirs | awk '/^install:/{print $2}'`
|
||||
default_newlib_io_c99_formats="yes"
|
||||
default_newlib_io_long_double="yes"
|
||||
default_newlib_io_long_long="yes"
|
||||
default_newlib_io_pos_args="yes"
|
||||
#newlib_cflags="${newlib_cflags} -Werror" # DEBUGGING ONLY;BREAKS BUILD
|
||||
newlib_cflags="${newlib_cflags} -Wall"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_FCNTL"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETOPT"
|
||||
newlib_cflags="${newlib_cflags} -D_NO_POSIX_SPAWN"
|
||||
# --- Required when building a shared library ------------------------
|
||||
newlib_cflags="${newlib_cflags} -fPIC -D_I386MACH_NEED_SOTYPE_FUNCTION"
|
||||
# --- The three lines below are optional ------------------------------
|
||||
##newlib_cflags="${newlib_cflags} -nostdinc"
|
||||
##newlib_cflags="${newlib_cflags} -I`newlib-flags --kernel-dir`/include"
|
||||
##newlib_cflags="${newlib_cflags} -idirafter ${gcc_dir}include"
|
||||
;;
|
||||
|
||||
m68hc11-*-*|m6811-*-*|m6812-*-*|m68hc12-*-*)
|
||||
;;
|
||||
|
|
Loading…
Reference in New Issue