aboutsummaryrefslogtreecommitdiff
path: root/ld/configure.host
AgeCommit message (Collapse)AuthorFilesLines
2017-01-02Run more ld tests when not nativeAlan Modra1-229/+2
Many of the ld tests are not run for cross builds, in some cases because the test needs to run a newly linked executable, and in others simply because it was easier to write the test for native only. Even when a test needs to run, it's good to compile and link to exercise the linker. So that's what this patch does. I've also rid us of the old ld_link procedure with all the HOSTING_CRT0 etc. setup. It's much simpler to just link with $CC. This does mean that a cross build with cross-compiler installed but no cross C-library will give lots of failures. If that turns out to be too annoying, I guess we can write a tcl procedure to detect it and not run all the extra tests. * Makefile.am (bootstrap): Delete rule. (ld-partial, ld1, ld1-full, ld2, ld3): Likewise. (HOSTING_CRT0, HOSTING_SCRT0): Don't define. (HOSTING_LIBS, HOSTING_SLIBS, HOSTING_EMU): Likewise. * configure.ac (HOSTING_CRT0, HOSTING_SCRT0): Don't define. (HOSTING_LIBS, HOSTING_SLIBS): Likewise. * configure.host (HOSTING_CRT0, HOSTING_LIBS): Don't define. * Makefile.in: Regenerate. * configure: Regenerate. * testsuite/config/default.exp (get_link_files): Delete. (HOSTING_CRT0, HOSTING_SCRT0, HOSTING_LIBS, HOSTING_SLIBS): Don't define. (ld_simple_link): Delete. * testsuite/lib/ld-lib.exp (default_ld_link): Delete (default_ld_simple_link): Rename to default_ld_link. (ld_simple_link_defsyms): Rename to ld_link_defsyms. (run_ld_link_tests): Use ld_link, not ld_simple_link. (run_cc_link_tests): Likewise. (run_ld_link_exec_tests): Use $CC or $CXX to link, not $ld. Don't run exe when not native, and return unsupported. * testsuite/ld-bootstrap/bootstrap.exp: Create gccld1 etc. dirs. Link ld1 etc. using $CC. * testsuite/ld-cdtest/cdtest.exp: Link cdtest using $CC. * testsuite/ld-checks/checks.exp: Use ld_link, not ld_simple_link. * testsuite/ld-cygwin/exe-export.exp: Likewise. * testsuite/ld-elf/binutils.exp: Likewise. * testsuite/ld-elf/eh-group.exp: Likewise. * testsuite/ld-elf/exclude.exp: Likewise. * testsuite/ld-elf/frame.exp: Likewise. * testsuite/ld-elf/sec-to-seg.exp: Likewise. * testsuite/ld-elf/tls_common.exp: Likewise. * testsuite/ld-elfcomm/elfcomm.exp: Likewise. * testsuite/ld-fastcall/fastcall.exp: Likewise. * testsuite/ld-gc/gc.exp: Likewise. * testsuite/ld-ifunc/binutils.exp: Likewise. * testsuite/ld-mep/mep.exp: Likewise. * testsuite/ld-mips-elf/mips-elf-flags.exp: Likewise. * testsuite/ld-mn10300/mn10300.exp: Likewise. * testsuite/ld-nios2/nios2.exp: Likewise. * testsuite/ld-pe/pe-compile.exp: Likewise. * testsuite/ld-pe/pe-run.exp: Likewise. * testsuite/ld-pe/pe-run2.exp: Likewise. * testsuite/ld-plugin/plugin.exp: Likewise. * testsuite/ld-scripts/align.exp: Likewise. * testsuite/ld-scripts/alignof.exp: Likewise. * testsuite/ld-scripts/assert.exp: Likewise. * testsuite/ld-scripts/defined.exp: Likewise. * testsuite/ld-scripts/extern.exp: Likewise. * testsuite/ld-scripts/log2.exp: Likewise. * testsuite/ld-scripts/map-address.exp: Likewise. * testsuite/ld-scripts/phdrs.exp: Likewise. * testsuite/ld-scripts/phdrs2.exp: Likewise. * testsuite/ld-scripts/script.exp: Likewise. * testsuite/ld-scripts/section-flags.exp: Likewise. * testsuite/ld-scripts/sizeof.exp: Likewise. * testsuite/ld-scripts/sysroot-prefix.exp: Likewise. * testsuite/ld-scripts/weak.exp: Likewise. * testsuite/ld-selective/selective.exp: Likewise. * testsuite/ld-sh/sh.exp: Likewise. * testsuite/ld-sh/sh64/relax.exp: Likewise. * testsuite/ld-sh/sh64/relfail.exp: Likewise. * testsuite/ld-srec/srec.exp: Likewise. * testsuite/ld-tic6x/tic6x.exp: Likewise. * testsuite/ld-undefined/weak-undef.exp: Likewise. * testsuite/ld-versados/versados.exp: Likewise. * testsuite/ld-x86-64/dwarfreloc.exp: Likewise. * testsuite/ld-xtensa/coalesce.exp: Likewise. * testsuite/ld-xtensa/diff_overflow.exp: Likewise. * testsuite/ld-xtensa/lcall.exp: Likewise. * testsuite/ld-elf/audit.exp: Run non-native too. * testsuite/ld-elf/compress.exp: Likewise. Replace ld options with gcc -Wl, options. * testsuite/ld-elf/dwarf.exp: Run non-native too. Use ld_link, not ld_simple_link. Add -Wl,--no-as-needed to some tests. * testsuite/ld-elf/elf.exp: Run non-native too. Formatting. * testsuite/ld-elf/indirect.exp: Run non-native too. Add -Wl,--no-as-needed to most tests. * testsuite/ld-elf/shared.exp: Run non-native too. Use braces to simplify quoting. Set run_tests using [list] rather than brace assignment to expand $extralibs. Add -Wl,--no-as-needed to many test. Prefix ld options with -Wl,. (mix_pic_and_non_pic): Don't run exe if not native. * testsuite/ld-elf/wrap.exp: Run non-native too. Add -Wl,--no-as-needed and prefix ld options with -Wl,. * testsuite/ld-elfvers/vers.exp: Run non-native too. Use ld_link, not ld_simple_link. * testsuite/ld-elfvsb/elfvsb.exp: Likewise. (visibility_test): Don't run exe if not native. * testsuite/ld-elfweak/elfweak.exp: Run non-native too. Use ld_link, not ld_simple_link. (build_exec): Don't run exe if not native. * testsuite/ld-ifunc/ifunc.exp: Run non-native too. Use ld_link, not ld_simple_link. Link using $CC. Add -Wl,--no-as-needed to some tests and prefix ld options with -Wl,. Expect GNU for hppa-linux even when no ifuncs. Delete cleanup. * testsuite/ld-pie/pie.exp: Run non-native too. * testsuite/ld-plugin/lto.exp: Likewise. * testsuite/ld-shared/shared.exp: Likewise. Use ld_link, not ld_simple_link. (shared_test): Don't run exe if not native. * testsuite/ld-size/size.exp: Run non-native too. Add -Wl,--no-as-needed to some tests. Prefix ld options with -Wl,. * testsuite/ld-unique/unique.exp: Run non-native too. Use ld_link, not ld_simple_link. Link using $CC. Add -Wl,--no-as-needed to some tests and prefix ld options with -Wl,. Expect GNU for hppa-linux even when no unique syms. Delete cleanup. * testsuite/ld-x86-64/tls.exp: Add -Wl,--no-as-needed to some tests and prefix ld options with -Wl,. * testsuite/ld-x86-64/x86-64.exp: Use ld_link, not ld_simple_link. Add -Wl,--no-as-needed to some tests. Prefix ld options with -Wl,.
2017-01-02Update year range in copyright notice of all files.Alan Modra1-1/+1
2016-01-01Copyright update for binutilsAlan Modra1-1/+1
2015-08-12Remove trailing spaces in ldH.J. Lu1-3/+3
2015-01-02ChangeLog rotatation and copyright year updateAlan Modra1-1/+1
2014-03-05Update copyright yearsAlan Modra1-1/+1
2013-11-26Fix a typoH.J. Lu1-1/+1
2013-11-26Add HOSTING_SLIBS and use it for -pieH.J. Lu1-0/+7
ld/ PR ld/16259 * Makefile.am (HOSTING_SLIBS): New. * configure.host (HOSTING_SLIBS): New. Used for PIE. * configure.in (HOSTING_SLIBS): New AC_SUBST. * Makefile.in: Regenerated. * configure: Likewise. ld/testsuite/ PR ld/16259 * config/default.exp (get_target_emul): Also set HOSTING_SLIBS. * lib/ld-lib.exp (default_ld_link): Use HOSTING_SLIBS for -pie.
2013-03-05 * configure.host: Add x86_64-*-cygwin* as valid host.Corinna Vinschen1-1/+1
* configure.tgt: Add x86_64-*-cygwin* as valid target. * emultempl/pep.em: Handle different requirements for Cygwin in terms of start addresses for executables and DLLs, based on memory model in http://cygwin.com/ml/cygwin-developers/2013-02/msg00027.html
2013-01-19Add HOSTING_SCRT0 for PIE testH.J. Lu1-0/+7
ld/ * Makefile.am (HOSTING_SCRT0): New. * configure.host (HOSTING_SCRT0): New. Used for PIE. * configure.in (HOSTING_SCRT0): New AC_SUBST. * Makefile.in: Regenerated. * configure: Likewise. ld/testsuite/ * config/default.exp (get_target_emul): Also set HOSTING_SCRT0. * lib/ld-lib.exp (default_ld_link): Use HOSTING_SCRT0 for -pie.
2012-12-17Add copyright noticesNick Clifton1-0/+17
2011-03-28Add support for DragonFlyBSD target.Nick Clifton1-2/+10
2010-12-21Adjust URLs.Thomas Schwinge1-1/+1
2010-11-08Improve binutils testsuite coverage for GNU/Hurd.Thomas Schwinge1-1/+10
binutils/testsuite/ * lib/utils-lib.exp (is_elf_format): Consider for *-*-gnu*, too. * binutils-all/elfedit-2.d (target): Likewise. * binutils-all/elfedit-3.d (target): Likewise. * binutils-all/i386/i386.exp: Likewise. * binutils-all/objcopy.exp: Likewise. * binutils-all/strip-3.d (target): Likewise. gas/testsuite/ * lib/gas-defs.exp (is_elf_format): Consider for *-*-gnu*, too. * gas/elf/elf.exp: Likewise. * gas/symver/symver.exp: Likewise. ld/ * configure.host: Add stanza for *-*-gnu*. ld/testsuite/ * lib/ld-lib.exp (is_elf_format): Consider for *-*-gnu*, too. * ld-discard/discard.exp: Likewise. * ld-elf/binutils.exp: Likewise. * ld-elf/commonpage1.d (target): Likewise. * ld-elf/compress1c.d (target): Likewise. * ld-elf/discard1.d (target): Likewise. * ld-elf/discard2.d (target): Likewise. * ld-elf/discard3.d (target): Likewise. * ld-elf/dynsym1.d (target): Likewise. * ld-elf/eh6.d (target): Likewise. * ld-elf/elf.exp: Likewise. (array_tests): Move -static tests to... (array_tests_static): ... here, and handle it accordingly. * ld-elf/hash.d (target): Likewise. * ld-elf/header.d (target): Likewise. * ld-elf/loadaddr1.d (target): Likewise. * ld-elf/loadaddr2.d (target): Likewise. * ld-elf/loadaddr3a.d (target): Likewise. * ld-elf/loadaddr3b.d (target): Likewise. * ld-elf/local1.d (target): Likewise. * ld-elf/maxpage1.d (target): Likewise. * ld-elf/maxpage2.d (target): Likewise. * ld-elf/maxpage3a.d (target): Likewise. * ld-elf/multibss1.d (target): Likewise. * ld-elf/noload-2.d (target): Likewise. * ld-elf/seg.d (target): Likewise. * ld-elf/textaddr1.d (target): Likewise. * ld-elf/textaddr2.d (target): Likewise. * ld-elf/textaddr3.d (target): Likewise. * ld-elf/textaddr4.d (target): Likewise. * ld-elf/textaddr5.d (target): Likewise. * ld-elf/textaddr6.d (target): Likewise. * ld-elf/textaddr7.d (target): Likewise. * ld-elf/tls_common.exp: Likewise. * ld-elf/unknown2.d (target): Likewise. * ld-elfvers/vers.exp: Likewise. * ld-elfvsb/elfvsb.exp: Likewise. * ld-elfweak/elfweak.exp: Likewise. (setup_xfail_gnu_hurd): New function. Use it where appropriate. * ld-gc/abi-note.d (target): Likewise. * ld-gc/gc.exp: Likewise. * ld-gc/pr11218.d (target): Likewise. * ld-gc/start.d (target): Likewise. * ld-i386/i386.exp: Likewise. * ld-ifunc/binutils.exp: Likewise. * ld-ifunc/ifunc.exp: Likewise. * ld-linkonce/linkonce.exp: Likewise. * ld-linkonce/zeroehl32.d (target): Likewise. * ld-pie/pie.exp: Likewise. * ld-scripts/phdrs2.exp: Likewise. * ld-scripts/rgn-at5.d (target): Likewise. * ld-shared/shared.exp: Likewise. * ld-undefined/entry-3.d (target): Likewise. * ld-undefined/entry-4.d (target): Likewise. * ld-undefined/weak-undef.exp: Likewise.
2010-03-25 PR ld/11426Alan Modra1-46/+4
* configure.host (many linux targets <HOSTING_CRT0>): Remove edits. (m68*-motorola-sysv <HOSTING_LIBS>): Use here doc, not echo.
2009-03-17ld/Alan Modra1-1/+1
* configure.host (HOSTING_LIBS): Two dollars on shell variable expansion to suit make. ld/testsuite * config/default.exp (get_link_files): Replace double dollars with single dollars.
2007-08-28Add support for i386-dragonfly target.Nick Clifton1-2/+2
2007-08-17 * config.bfd: Handle sparcv*-*-linux-* the same as sparc-*-linux-*.Jakub Jelinek1-2/+2
Change sparc64-*-linux-* to sparc64*-*-linux-*. * configure.host: Handle sparcv*-*-linux-* the same as sparc-*-linux-*. Change sparc64-*-linux-* to sparc64*-*-linux-*. * ld-sparc/tlssunnopic32.dd: Fix up #target. * ld-sparc/tlssunnopic32.rd: Likewise. * ld-sparc/tlssunnopic32.sd: Likewise. * ld-sparc/tlssunnopic64.dd: Likewise. * ld-sparc/tlssunnopic64.rd: Likewise. * ld-sparc/tlssunnopic64.sd: Likewise.
2007-01-08* configure.host: Add i[3-7]86-*-mingw* case.Nick Clifton1-0/+6
2005-07-192005-07-19 Paul Brook <paul@codesourcery.com>Paul Brook1-1/+1
* configure.host (HOSTING_CRT0): Parse output of gcc --help --verbose to determine dynamic linker name.
2005-05-26* configure.host (HOSTING_LIBS): Add libunwind.a if it exists.Andreas Schwab1-1/+1
2005-04-24* configure.host: Add *-*-openbsd support.Mark Kettenis1-0/+9
2005-03-23Accept any C library to accompany a GNU Linux implementation, not just the GNUNick Clifton1-11/+11
C library.
2005-01-11 * configure.host: Correct sed patterns for last change.Alan Modra1-9/+9
2005-01-10(linux targets): Use "${CC} -dumpspecs" instead of "${CC} ↵Nick Clifton1-6/+1
--print-file-name=specs" to appease GCC versions >= 4.0. (ia64-*-aix): Delete - this target is obsolete, and would be broken by this patch.
2005-01-06 * configure.host (sparc*-*-solaris2*): Rename into sparc-*-solaris2*.Eric Botcazou1-1/+6
(sparc64-sun-solaris2*): New host.
2004-05-17Add PowerPC LynxOS supportNick Clifton1-10/+0
2004-04-11 /bfd/ChangeLogThiemo Seufer1-4/+0
* config.bfd: Remove mips*-*-mach3* and mips*-dec-mach3* targets. * configure.in: Remove mips-dec-bsd*, mips-dec-mach3*, mips-*-mach3* targets amd aout_mips_big_vec, aout_mips_little_vec target vectors. * configure: Regenerate. /gas/ChangeLog * Makefile.am: Remove mips from aout targets. * Makefile.in: Regenerate. * configure.in: Remove mips-dec-bsd* target. * configure: Regenerate. /ld/ChangeLog * configure.host: Remove mips*-dec-bsd* target. * configure.tgt: Likewise.
2003-11-09 * configure.host (HOSTING_LIBS): Group libgcc and libc withAlan Modra1-14/+4
--start-group, --end-group pair. (*-*-netbsd*, am33_2.0-*-linux*): Use the default HOSTING_LIBS. (am33_2.0-*-linux*): Edit default HOSTING_CRT0. (arm*-*-linux-gnu*): Remove extraneous '*' in sed expression. (hppa*64*-*-linux*, hppa*-*-linux*): Remove target specific case.
2003-10-07 * configure.host (HOSTING_LIBS): Define for hppa*-*-linux*.Dave Anglin1-0/+8
* ld-elfvsb/elfvsb.exp: xfail non-pic shared library tests for non 64-bit hppa*-*-linux* targets. * ld-elfvsb/main.c (main_visibility_check): Cast value returned by visibility_funptr () to a function pointer. * ld-shared/shared.exp: xfail shared (non PIC), shared (non PIC, load offset), and shared (PIC main, non PIC so) tests for non 64-bit hppa*-*-linux* targets.
2003-09-03Add *kfreebsd-gnu configuration supportNick Clifton1-2/+2
2003-07-102001-08-22 Alexandre Oliva <aoliva@redhat.com>Alexandre Oliva1-0/+5
* emulparams/elf32am33lin.sh: Adjust to match kernel parameters. 2001-05-09 Alexandre Oliva <aoliva@redhat.com> * configure.host (am33_2.0-*-linux*): Added. * configure.tgt (am33_2.0-*-linux*): Likewise. * emulparams/elf32am33lin.sh: New. * Makefile.am (eelf32am33lin.c): New rule. * Makefile.in: Rebuilt.
2003-06-17* ld-undefined/undefined.exp (i?86-*-freebsd*): Remove xfail.Nick Clifton1-5/+1
* configure.host (*-*-freebsd*): Add known path for ld-elf.so.1 if not produced by gcc.
2003-05-29* configure.host (*-*-netbsd*): Set HOSTING_CRT0 and HOSTING_LIBSJason Thorpe1-8/+32
correctly for more recent versions of NetBSD. (alpha*-*-netbsd*): Remove. (i[3-7]86-*-netbsd*): Remove.
2003-05-16Replace i[3456]86 with i[3-7]86Nick Clifton1-9/+9
2003-01-06 * Makefile.am (eelf32iq10.c): Fix tab/whitespace mixup.Daniel Jacobowitz1-10/+0
* Makefile.am (ldmain.o): Add @TARGET_SYSTEM_ROOT_DEFINE@. (GENSCRIPTS): Add @use_sysroot@. * Makefile.in: Regenerated. * configure.host: Move setting of NATIVE_LIB_DIRS to... * configure.tgt: ... here. Use ${target} instead of ${host} for NATIVE_LIB_DIRS. * configure.in: Add --with-sysroot. * configure: Regenerated. * genscripts.sh: Accept use_sysroot option. Set new variables NATIVE and USE_LIBPATH. Prepend "=" to directory names if $use_sysroot. Don't search $tool_lib if $use_sysroot. * ldfile.c (ldfile_add_library_path): Handle leading '='. * ldmain.c (TARGET_SYSTEM_ROOT): Define if not defined. (ld_sysroot): New variable. (main): Initialize ld_sysroot. * ldmain.h (ld_sysroot): New extern. * emultempl/elf32.em: Use NATIVE and USE_LIBPATH instead of searching $EMULATION_LIBPATH. (gld${EMULATION_NAME}_add_sysroot): New function. (gld${EMULATION_NAME}_check_ld_so_conf): Use it. Honor ld_sysroot. (gld${EMULATION_NAME}_after_open): Likewise. Only search environment variables if $NATIVE. * ld.texinfo (Options): Mention "=" prefix in the description of -L. * NEWS: Mention --with-sysroot. * emulparams/elf32bmipn32-defs.sh: Set NATIVE and LIBPATH_SUFFIX instead of setting LIB_PATH. * emulparams/elf32ppc.sh: Likewise. * emulparams/elf64_s390.sh: Likewise. * emulparams/elf64_sparc.sh: Likewise. * emulparams/elf64ppc.sh: Likewise. * emulparams/elf_x86_64.sh: Likewise. * emulparams/elf64_aix.sh: Add "=" prefixes to LIB_PATH. * emulparams/elf64hppa.sh: Add "=" prefixes to LIB_PATH.
2002-12-18Add win32 library search path.Nick Clifton1-1/+1
2002-11-30 * configure.host: Correct dynamic-linker for powerpc64 hosts.Alan Modra1-0/+4
2002-11-282002-11-27 David O'Brien <obrien@FreeBSD.org>David O'Brien1-1/+1
* configure.host: Fix generic FreeBSD configuration entry.
2002-06-20Remove romp targetNick Clifton1-4/+0
2002-06-06 * configure.host (hppa*64*-*-hpux11*): Define NATIVE_LIB_DIRS,Jeff Law1-0/+7
HOSTING_CRT0 and HOSTING_LIBS.
2002-05-22 * genscripts.sh (LIB_PATH): For native targets, concatenate $libdirAlan Modra1-19/+8
and $NATIVE_LIB_DIRS. Add $tool_lib before other libs. (LIB_SEARCH_DIRS): No need to use "tr". (COMPILE_IN): Only set for native targets. * configure.host (NATIVE_LIB_DIRS): Specify all native search dirs here, rather than adding lib:/usr/lib:/usr/local/lib in genscripts.sh. * configure.tgt (powerpc*): Set tdir_*. (powerpcle*): Correct targ_extra_emuls. * emulparams/elf32ppc.sh (LIB_PATH): Set up native 64 bit dirs. * emulparams/elf64ppc.sh (LIB_PATH): Likewise.
2002-04-07* ld/configure.host (*-*-netbsd*): Add support for NetBSD/ELF.Matthew Green1-0/+7
2002-03-27 * configure.host: Set up for generic hosts first, then tweak asAlan Modra1-78/+67
necessary in more specific targets. (HOSTING_LIBS): Include libgcc_eh.a if found.
2001-12-19 * configure.host: Add rules for x86_64-*linux-gnu. ChangeAndreas Jaeger1-4/+9
s390x-linux entry to use gcc to report configuration, replace gcc with $CC in s390-linux
2001-10-23 * configure.host: Move alpha*-*-linux-gnu* entry to genericAlan Modra1-5/+5
entries, and match *-*-linux*.
2001-06-06 * configure.host: Set HOSTING_CRT0/HOSTING_LIBS correctly for s/390.Alan Modra1-3/+3
2001-05-25s/linuxaout/linux*aout/, s/linuxoldld/linux*oldld/Alan Modra1-1/+1
2001-02-22Add ia64-*-aix* configuration.Timothy Wall1-0/+6
2001-02-182001-02-17 David O'Brien <obrien@FreeBSD.org>David O'Brien1-24/+24
* configure.host: Add a generic FreeBSD configuration entry such that all [modern] FreeBSD systems on all platforms will look the same. Approved by: Alan Modra <alan@linuxcare.com.au> <Pine.LNX.4.21.0102172155140.30011-100000@front.linuxcare.com.au>